
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of google-ads-stubs-v18 Show documentation
Show all versions of google-ads-stubs-v18 Show documentation
Stubs for GAAPI version google-ads-stubs-v18
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/ads/googleads/v18/services/recommendation_service.proto
// Protobuf Java Version: 3.25.3
package com.google.ads.googleads.v18.services;
/**
*
* Request message for
* [RecommendationService.GenerateRecommendations][google.ads.googleads.v18.services.RecommendationService.GenerateRecommendations].
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest}
*/
public final class GenerateRecommendationsRequest extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest)
GenerateRecommendationsRequestOrBuilder {
private static final long serialVersionUID = 0L;
// Use GenerateRecommendationsRequest.newBuilder() to construct.
private GenerateRecommendationsRequest(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private GenerateRecommendationsRequest() {
customerId_ = "";
recommendationTypes_ = java.util.Collections.emptyList();
advertisingChannelType_ = 0;
conversionTrackingStatus_ = 0;
adGroupInfo_ = java.util.Collections.emptyList();
countryCodes_ =
com.google.protobuf.LazyStringArrayList.emptyList();
languageCodes_ =
com.google.protobuf.LazyStringArrayList.emptyList();
positiveLocationsIds_ = emptyLongList();
negativeLocationsIds_ = emptyLongList();
assetGroupInfo_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new GenerateRecommendationsRequest();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.Builder.class);
}
public interface BiddingInfoOrBuilder extends
// @@protoc_insertion_point(interface_extends:google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo)
com.google.protobuf.MessageOrBuilder {
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @return Whether the biddingStrategyType field is set.
*/
boolean hasBiddingStrategyType();
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @return The enum numeric value on the wire for biddingStrategyType.
*/
int getBiddingStrategyTypeValue();
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @return The biddingStrategyType.
*/
com.google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType getBiddingStrategyType();
/**
*
* Current target_cpa in micros.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_CPA or MAXIMIZE_CONVERSIONS.
*
*
* int64 target_cpa_micros = 2;
* @return Whether the targetCpaMicros field is set.
*/
boolean hasTargetCpaMicros();
/**
*
* Current target_cpa in micros.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_CPA or MAXIMIZE_CONVERSIONS.
*
*
* int64 target_cpa_micros = 2;
* @return The targetCpaMicros.
*/
long getTargetCpaMicros();
/**
*
* Current target_roas.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_ROAS or MAXIMIZE_CONVERSION_VALUE.
*
*
* double target_roas = 3;
* @return Whether the targetRoas field is set.
*/
boolean hasTargetRoas();
/**
*
* Current target_roas.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_ROAS or MAXIMIZE_CONVERSION_VALUE.
*
*
* double target_roas = 3;
* @return The targetRoas.
*/
double getTargetRoas();
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the targetImpressionShareInfo field is set.
*/
boolean hasTargetImpressionShareInfo();
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return The targetImpressionShareInfo.
*/
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo getTargetImpressionShareInfo();
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
*/
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfoOrBuilder getTargetImpressionShareInfoOrBuilder();
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.BiddingStrategyTargetInfoCase getBiddingStrategyTargetInfoCase();
}
/**
*
* Current bidding information of the campaign. Provides a wrapper for
* bidding-related signals that inform recommendations.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo}
*/
public static final class BiddingInfo extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo)
BiddingInfoOrBuilder {
private static final long serialVersionUID = 0L;
// Use BiddingInfo.newBuilder() to construct.
private BiddingInfo(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private BiddingInfo() {
biddingStrategyType_ = 0;
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new BiddingInfo();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_BiddingInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_BiddingInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.Builder.class);
}
private int bitField0_;
private int biddingStrategyTargetInfoCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object biddingStrategyTargetInfo_;
public enum BiddingStrategyTargetInfoCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
TARGET_CPA_MICROS(2),
TARGET_ROAS(3),
TARGET_IMPRESSION_SHARE_INFO(4),
BIDDINGSTRATEGYTARGETINFO_NOT_SET(0);
private final int value;
private BiddingStrategyTargetInfoCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static BiddingStrategyTargetInfoCase valueOf(int value) {
return forNumber(value);
}
public static BiddingStrategyTargetInfoCase forNumber(int value) {
switch (value) {
case 2: return TARGET_CPA_MICROS;
case 3: return TARGET_ROAS;
case 4: return TARGET_IMPRESSION_SHARE_INFO;
case 0: return BIDDINGSTRATEGYTARGETINFO_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public BiddingStrategyTargetInfoCase
getBiddingStrategyTargetInfoCase() {
return BiddingStrategyTargetInfoCase.forNumber(
biddingStrategyTargetInfoCase_);
}
public static final int BIDDING_STRATEGY_TYPE_FIELD_NUMBER = 1;
private int biddingStrategyType_ = 0;
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @return Whether the biddingStrategyType field is set.
*/
@java.lang.Override public boolean hasBiddingStrategyType() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @return The enum numeric value on the wire for biddingStrategyType.
*/
@java.lang.Override public int getBiddingStrategyTypeValue() {
return biddingStrategyType_;
}
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @return The biddingStrategyType.
*/
@java.lang.Override public com.google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType getBiddingStrategyType() {
com.google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType result = com.google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType.forNumber(biddingStrategyType_);
return result == null ? com.google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType.UNRECOGNIZED : result;
}
public static final int TARGET_CPA_MICROS_FIELD_NUMBER = 2;
/**
*
* Current target_cpa in micros.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_CPA or MAXIMIZE_CONVERSIONS.
*
*
* int64 target_cpa_micros = 2;
* @return Whether the targetCpaMicros field is set.
*/
@java.lang.Override
public boolean hasTargetCpaMicros() {
return biddingStrategyTargetInfoCase_ == 2;
}
/**
*
* Current target_cpa in micros.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_CPA or MAXIMIZE_CONVERSIONS.
*
*
* int64 target_cpa_micros = 2;
* @return The targetCpaMicros.
*/
@java.lang.Override
public long getTargetCpaMicros() {
if (biddingStrategyTargetInfoCase_ == 2) {
return (java.lang.Long) biddingStrategyTargetInfo_;
}
return 0L;
}
public static final int TARGET_ROAS_FIELD_NUMBER = 3;
/**
*
* Current target_roas.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_ROAS or MAXIMIZE_CONVERSION_VALUE.
*
*
* double target_roas = 3;
* @return Whether the targetRoas field is set.
*/
@java.lang.Override
public boolean hasTargetRoas() {
return biddingStrategyTargetInfoCase_ == 3;
}
/**
*
* Current target_roas.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_ROAS or MAXIMIZE_CONVERSION_VALUE.
*
*
* double target_roas = 3;
* @return The targetRoas.
*/
@java.lang.Override
public double getTargetRoas() {
if (biddingStrategyTargetInfoCase_ == 3) {
return (java.lang.Double) biddingStrategyTargetInfo_;
}
return 0D;
}
public static final int TARGET_IMPRESSION_SHARE_INFO_FIELD_NUMBER = 4;
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the targetImpressionShareInfo field is set.
*/
@java.lang.Override
public boolean hasTargetImpressionShareInfo() {
return biddingStrategyTargetInfoCase_ == 4;
}
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return The targetImpressionShareInfo.
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo getTargetImpressionShareInfo() {
if (biddingStrategyTargetInfoCase_ == 4) {
return (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo) biddingStrategyTargetInfo_;
}
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.getDefaultInstance();
}
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfoOrBuilder getTargetImpressionShareInfoOrBuilder() {
if (biddingStrategyTargetInfoCase_ == 4) {
return (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo) biddingStrategyTargetInfo_;
}
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.getDefaultInstance();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
output.writeEnum(1, biddingStrategyType_);
}
if (biddingStrategyTargetInfoCase_ == 2) {
output.writeInt64(
2, (long)((java.lang.Long) biddingStrategyTargetInfo_));
}
if (biddingStrategyTargetInfoCase_ == 3) {
output.writeDouble(
3, (double)((java.lang.Double) biddingStrategyTargetInfo_));
}
if (biddingStrategyTargetInfoCase_ == 4) {
output.writeMessage(4, (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo) biddingStrategyTargetInfo_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, biddingStrategyType_);
}
if (biddingStrategyTargetInfoCase_ == 2) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(
2, (long)((java.lang.Long) biddingStrategyTargetInfo_));
}
if (biddingStrategyTargetInfoCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeDoubleSize(
3, (double)((java.lang.Double) biddingStrategyTargetInfo_));
}
if (biddingStrategyTargetInfoCase_ == 4) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo) biddingStrategyTargetInfo_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo)) {
return super.equals(obj);
}
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo other = (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo) obj;
if (hasBiddingStrategyType() != other.hasBiddingStrategyType()) return false;
if (hasBiddingStrategyType()) {
if (biddingStrategyType_ != other.biddingStrategyType_) return false;
}
if (!getBiddingStrategyTargetInfoCase().equals(other.getBiddingStrategyTargetInfoCase())) return false;
switch (biddingStrategyTargetInfoCase_) {
case 2:
if (getTargetCpaMicros()
!= other.getTargetCpaMicros()) return false;
break;
case 3:
if (java.lang.Double.doubleToLongBits(getTargetRoas())
!= java.lang.Double.doubleToLongBits(
other.getTargetRoas())) return false;
break;
case 4:
if (!getTargetImpressionShareInfo()
.equals(other.getTargetImpressionShareInfo())) return false;
break;
case 0:
default:
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasBiddingStrategyType()) {
hash = (37 * hash) + BIDDING_STRATEGY_TYPE_FIELD_NUMBER;
hash = (53 * hash) + biddingStrategyType_;
}
switch (biddingStrategyTargetInfoCase_) {
case 2:
hash = (37 * hash) + TARGET_CPA_MICROS_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getTargetCpaMicros());
break;
case 3:
hash = (37 * hash) + TARGET_ROAS_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
java.lang.Double.doubleToLongBits(getTargetRoas()));
break;
case 4:
hash = (37 * hash) + TARGET_IMPRESSION_SHARE_INFO_FIELD_NUMBER;
hash = (53 * hash) + getTargetImpressionShareInfo().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Current bidding information of the campaign. Provides a wrapper for
* bidding-related signals that inform recommendations.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo)
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfoOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_BiddingInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_BiddingInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.Builder.class);
}
// Construct using com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
biddingStrategyType_ = 0;
if (targetImpressionShareInfoBuilder_ != null) {
targetImpressionShareInfoBuilder_.clear();
}
biddingStrategyTargetInfoCase_ = 0;
biddingStrategyTargetInfo_ = null;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_BiddingInfo_descriptor;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo getDefaultInstanceForType() {
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.getDefaultInstance();
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo build() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo buildPartial() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo result = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo(this);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartial0(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.biddingStrategyType_ = biddingStrategyType_;
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
private void buildPartialOneofs(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo result) {
result.biddingStrategyTargetInfoCase_ = biddingStrategyTargetInfoCase_;
result.biddingStrategyTargetInfo_ = this.biddingStrategyTargetInfo_;
if (biddingStrategyTargetInfoCase_ == 4 &&
targetImpressionShareInfoBuilder_ != null) {
result.biddingStrategyTargetInfo_ = targetImpressionShareInfoBuilder_.build();
}
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo) {
return mergeFrom((com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo other) {
if (other == com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.getDefaultInstance()) return this;
if (other.hasBiddingStrategyType()) {
setBiddingStrategyType(other.getBiddingStrategyType());
}
switch (other.getBiddingStrategyTargetInfoCase()) {
case TARGET_CPA_MICROS: {
setTargetCpaMicros(other.getTargetCpaMicros());
break;
}
case TARGET_ROAS: {
setTargetRoas(other.getTargetRoas());
break;
}
case TARGET_IMPRESSION_SHARE_INFO: {
mergeTargetImpressionShareInfo(other.getTargetImpressionShareInfo());
break;
}
case BIDDINGSTRATEGYTARGETINFO_NOT_SET: {
break;
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
biddingStrategyType_ = input.readEnum();
bitField0_ |= 0x00000001;
break;
} // case 8
case 16: {
biddingStrategyTargetInfo_ = input.readInt64();
biddingStrategyTargetInfoCase_ = 2;
break;
} // case 16
case 25: {
biddingStrategyTargetInfo_ = input.readDouble();
biddingStrategyTargetInfoCase_ = 3;
break;
} // case 25
case 34: {
input.readMessage(
getTargetImpressionShareInfoFieldBuilder().getBuilder(),
extensionRegistry);
biddingStrategyTargetInfoCase_ = 4;
break;
} // case 34
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int biddingStrategyTargetInfoCase_ = 0;
private java.lang.Object biddingStrategyTargetInfo_;
public BiddingStrategyTargetInfoCase
getBiddingStrategyTargetInfoCase() {
return BiddingStrategyTargetInfoCase.forNumber(
biddingStrategyTargetInfoCase_);
}
public Builder clearBiddingStrategyTargetInfo() {
biddingStrategyTargetInfoCase_ = 0;
biddingStrategyTargetInfo_ = null;
onChanged();
return this;
}
private int bitField0_;
private int biddingStrategyType_ = 0;
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @return Whether the biddingStrategyType field is set.
*/
@java.lang.Override public boolean hasBiddingStrategyType() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @return The enum numeric value on the wire for biddingStrategyType.
*/
@java.lang.Override public int getBiddingStrategyTypeValue() {
return biddingStrategyType_;
}
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @param value The enum numeric value on the wire for biddingStrategyType to set.
* @return This builder for chaining.
*/
public Builder setBiddingStrategyTypeValue(int value) {
biddingStrategyType_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @return The biddingStrategyType.
*/
@java.lang.Override
public com.google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType getBiddingStrategyType() {
com.google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType result = com.google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType.forNumber(biddingStrategyType_);
return result == null ? com.google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType.UNRECOGNIZED : result;
}
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @param value The biddingStrategyType to set.
* @return This builder for chaining.
*/
public Builder setBiddingStrategyType(com.google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000001;
biddingStrategyType_ = value.getNumber();
onChanged();
return this;
}
/**
*
* Current bidding strategy.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.BiddingStrategyTypeEnum.BiddingStrategyType bidding_strategy_type = 1;
* @return This builder for chaining.
*/
public Builder clearBiddingStrategyType() {
bitField0_ = (bitField0_ & ~0x00000001);
biddingStrategyType_ = 0;
onChanged();
return this;
}
/**
*
* Current target_cpa in micros.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_CPA or MAXIMIZE_CONVERSIONS.
*
*
* int64 target_cpa_micros = 2;
* @return Whether the targetCpaMicros field is set.
*/
public boolean hasTargetCpaMicros() {
return biddingStrategyTargetInfoCase_ == 2;
}
/**
*
* Current target_cpa in micros.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_CPA or MAXIMIZE_CONVERSIONS.
*
*
* int64 target_cpa_micros = 2;
* @return The targetCpaMicros.
*/
public long getTargetCpaMicros() {
if (biddingStrategyTargetInfoCase_ == 2) {
return (java.lang.Long) biddingStrategyTargetInfo_;
}
return 0L;
}
/**
*
* Current target_cpa in micros.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_CPA or MAXIMIZE_CONVERSIONS.
*
*
* int64 target_cpa_micros = 2;
* @param value The targetCpaMicros to set.
* @return This builder for chaining.
*/
public Builder setTargetCpaMicros(long value) {
biddingStrategyTargetInfoCase_ = 2;
biddingStrategyTargetInfo_ = value;
onChanged();
return this;
}
/**
*
* Current target_cpa in micros.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_CPA or MAXIMIZE_CONVERSIONS.
*
*
* int64 target_cpa_micros = 2;
* @return This builder for chaining.
*/
public Builder clearTargetCpaMicros() {
if (biddingStrategyTargetInfoCase_ == 2) {
biddingStrategyTargetInfoCase_ = 0;
biddingStrategyTargetInfo_ = null;
onChanged();
}
return this;
}
/**
*
* Current target_roas.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_ROAS or MAXIMIZE_CONVERSION_VALUE.
*
*
* double target_roas = 3;
* @return Whether the targetRoas field is set.
*/
public boolean hasTargetRoas() {
return biddingStrategyTargetInfoCase_ == 3;
}
/**
*
* Current target_roas.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_ROAS or MAXIMIZE_CONVERSION_VALUE.
*
*
* double target_roas = 3;
* @return The targetRoas.
*/
public double getTargetRoas() {
if (biddingStrategyTargetInfoCase_ == 3) {
return (java.lang.Double) biddingStrategyTargetInfo_;
}
return 0D;
}
/**
*
* Current target_roas.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_ROAS or MAXIMIZE_CONVERSION_VALUE.
*
*
* double target_roas = 3;
* @param value The targetRoas to set.
* @return This builder for chaining.
*/
public Builder setTargetRoas(double value) {
biddingStrategyTargetInfoCase_ = 3;
biddingStrategyTargetInfo_ = value;
onChanged();
return this;
}
/**
*
* Current target_roas.
* This can be populated for campaigns with a bidding strategy type of
* TARGET_ROAS or MAXIMIZE_CONVERSION_VALUE.
*
*
* double target_roas = 3;
* @return This builder for chaining.
*/
public Builder clearTargetRoas() {
if (biddingStrategyTargetInfoCase_ == 3) {
biddingStrategyTargetInfoCase_ = 0;
biddingStrategyTargetInfo_ = null;
onChanged();
}
return this;
}
private com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfoOrBuilder> targetImpressionShareInfoBuilder_;
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the targetImpressionShareInfo field is set.
*/
@java.lang.Override
public boolean hasTargetImpressionShareInfo() {
return biddingStrategyTargetInfoCase_ == 4;
}
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return The targetImpressionShareInfo.
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo getTargetImpressionShareInfo() {
if (targetImpressionShareInfoBuilder_ == null) {
if (biddingStrategyTargetInfoCase_ == 4) {
return (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo) biddingStrategyTargetInfo_;
}
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.getDefaultInstance();
} else {
if (biddingStrategyTargetInfoCase_ == 4) {
return targetImpressionShareInfoBuilder_.getMessage();
}
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.getDefaultInstance();
}
}
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setTargetImpressionShareInfo(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo value) {
if (targetImpressionShareInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
biddingStrategyTargetInfo_ = value;
onChanged();
} else {
targetImpressionShareInfoBuilder_.setMessage(value);
}
biddingStrategyTargetInfoCase_ = 4;
return this;
}
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setTargetImpressionShareInfo(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.Builder builderForValue) {
if (targetImpressionShareInfoBuilder_ == null) {
biddingStrategyTargetInfo_ = builderForValue.build();
onChanged();
} else {
targetImpressionShareInfoBuilder_.setMessage(builderForValue.build());
}
biddingStrategyTargetInfoCase_ = 4;
return this;
}
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder mergeTargetImpressionShareInfo(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo value) {
if (targetImpressionShareInfoBuilder_ == null) {
if (biddingStrategyTargetInfoCase_ == 4 &&
biddingStrategyTargetInfo_ != com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.getDefaultInstance()) {
biddingStrategyTargetInfo_ = com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.newBuilder((com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo) biddingStrategyTargetInfo_)
.mergeFrom(value).buildPartial();
} else {
biddingStrategyTargetInfo_ = value;
}
onChanged();
} else {
if (biddingStrategyTargetInfoCase_ == 4) {
targetImpressionShareInfoBuilder_.mergeFrom(value);
} else {
targetImpressionShareInfoBuilder_.setMessage(value);
}
}
biddingStrategyTargetInfoCase_ = 4;
return this;
}
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder clearTargetImpressionShareInfo() {
if (targetImpressionShareInfoBuilder_ == null) {
if (biddingStrategyTargetInfoCase_ == 4) {
biddingStrategyTargetInfoCase_ = 0;
biddingStrategyTargetInfo_ = null;
onChanged();
}
} else {
if (biddingStrategyTargetInfoCase_ == 4) {
biddingStrategyTargetInfoCase_ = 0;
biddingStrategyTargetInfo_ = null;
}
targetImpressionShareInfoBuilder_.clear();
}
return this;
}
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.Builder getTargetImpressionShareInfoBuilder() {
return getTargetImpressionShareInfoFieldBuilder().getBuilder();
}
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfoOrBuilder getTargetImpressionShareInfoOrBuilder() {
if ((biddingStrategyTargetInfoCase_ == 4) && (targetImpressionShareInfoBuilder_ != null)) {
return targetImpressionShareInfoBuilder_.getMessageOrBuilder();
} else {
if (biddingStrategyTargetInfoCase_ == 4) {
return (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo) biddingStrategyTargetInfo_;
}
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.getDefaultInstance();
}
}
/**
*
* Optional. Current Target Impression Share information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* .google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo target_impression_share_info = 4 [(.google.api.field_behavior) = OPTIONAL];
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfoOrBuilder>
getTargetImpressionShareInfoFieldBuilder() {
if (targetImpressionShareInfoBuilder_ == null) {
if (!(biddingStrategyTargetInfoCase_ == 4)) {
biddingStrategyTargetInfo_ = com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.getDefaultInstance();
}
targetImpressionShareInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfoOrBuilder>(
(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo) biddingStrategyTargetInfo_,
getParentForChildren(),
isClean());
biddingStrategyTargetInfo_ = null;
}
biddingStrategyTargetInfoCase_ = 4;
onChanged();
return targetImpressionShareInfoBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo)
}
// @@protoc_insertion_point(class_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo)
private static final com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo();
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public BiddingInfo parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface AdGroupInfoOrBuilder extends
// @@protoc_insertion_point(interface_extends:google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo)
com.google.protobuf.MessageOrBuilder {
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the adGroupType field is set.
*/
boolean hasAdGroupType();
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @return The enum numeric value on the wire for adGroupType.
*/
int getAdGroupTypeValue();
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @return The adGroupType.
*/
com.google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType getAdGroupType();
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
java.util.List
getKeywordsList();
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
com.google.ads.googleads.v18.common.KeywordInfo getKeywords(int index);
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
int getKeywordsCount();
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
java.util.List extends com.google.ads.googleads.v18.common.KeywordInfoOrBuilder>
getKeywordsOrBuilderList();
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
com.google.ads.googleads.v18.common.KeywordInfoOrBuilder getKeywordsOrBuilder(
int index);
}
/**
*
* Current AdGroup Information of the campaign.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo}
*/
public static final class AdGroupInfo extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo)
AdGroupInfoOrBuilder {
private static final long serialVersionUID = 0L;
// Use AdGroupInfo.newBuilder() to construct.
private AdGroupInfo(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private AdGroupInfo() {
adGroupType_ = 0;
keywords_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new AdGroupInfo();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_AdGroupInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_AdGroupInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder.class);
}
private int bitField0_;
public static final int AD_GROUP_TYPE_FIELD_NUMBER = 1;
private int adGroupType_ = 0;
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the adGroupType field is set.
*/
@java.lang.Override public boolean hasAdGroupType() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @return The enum numeric value on the wire for adGroupType.
*/
@java.lang.Override public int getAdGroupTypeValue() {
return adGroupType_;
}
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @return The adGroupType.
*/
@java.lang.Override public com.google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType getAdGroupType() {
com.google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType result = com.google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType.forNumber(adGroupType_);
return result == null ? com.google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType.UNRECOGNIZED : result;
}
public static final int KEYWORDS_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private java.util.List keywords_;
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public java.util.List getKeywordsList() {
return keywords_;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public java.util.List extends com.google.ads.googleads.v18.common.KeywordInfoOrBuilder>
getKeywordsOrBuilderList() {
return keywords_;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public int getKeywordsCount() {
return keywords_.size();
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.common.KeywordInfo getKeywords(int index) {
return keywords_.get(index);
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.common.KeywordInfoOrBuilder getKeywordsOrBuilder(
int index) {
return keywords_.get(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
output.writeEnum(1, adGroupType_);
}
for (int i = 0; i < keywords_.size(); i++) {
output.writeMessage(2, keywords_.get(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, adGroupType_);
}
for (int i = 0; i < keywords_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, keywords_.get(i));
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo)) {
return super.equals(obj);
}
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo other = (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo) obj;
if (hasAdGroupType() != other.hasAdGroupType()) return false;
if (hasAdGroupType()) {
if (adGroupType_ != other.adGroupType_) return false;
}
if (!getKeywordsList()
.equals(other.getKeywordsList())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasAdGroupType()) {
hash = (37 * hash) + AD_GROUP_TYPE_FIELD_NUMBER;
hash = (53 * hash) + adGroupType_;
}
if (getKeywordsCount() > 0) {
hash = (37 * hash) + KEYWORDS_FIELD_NUMBER;
hash = (53 * hash) + getKeywordsList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Current AdGroup Information of the campaign.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo)
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfoOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_AdGroupInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_AdGroupInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder.class);
}
// Construct using com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
adGroupType_ = 0;
if (keywordsBuilder_ == null) {
keywords_ = java.util.Collections.emptyList();
} else {
keywords_ = null;
keywordsBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000002);
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_AdGroupInfo_descriptor;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo getDefaultInstanceForType() {
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.getDefaultInstance();
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo build() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo buildPartial() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo result = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo result) {
if (keywordsBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0)) {
keywords_ = java.util.Collections.unmodifiableList(keywords_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.keywords_ = keywords_;
} else {
result.keywords_ = keywordsBuilder_.build();
}
}
private void buildPartial0(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.adGroupType_ = adGroupType_;
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo) {
return mergeFrom((com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo other) {
if (other == com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.getDefaultInstance()) return this;
if (other.hasAdGroupType()) {
setAdGroupType(other.getAdGroupType());
}
if (keywordsBuilder_ == null) {
if (!other.keywords_.isEmpty()) {
if (keywords_.isEmpty()) {
keywords_ = other.keywords_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureKeywordsIsMutable();
keywords_.addAll(other.keywords_);
}
onChanged();
}
} else {
if (!other.keywords_.isEmpty()) {
if (keywordsBuilder_.isEmpty()) {
keywordsBuilder_.dispose();
keywordsBuilder_ = null;
keywords_ = other.keywords_;
bitField0_ = (bitField0_ & ~0x00000002);
keywordsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getKeywordsFieldBuilder() : null;
} else {
keywordsBuilder_.addAllMessages(other.keywords_);
}
}
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
adGroupType_ = input.readEnum();
bitField0_ |= 0x00000001;
break;
} // case 8
case 18: {
com.google.ads.googleads.v18.common.KeywordInfo m =
input.readMessage(
com.google.ads.googleads.v18.common.KeywordInfo.parser(),
extensionRegistry);
if (keywordsBuilder_ == null) {
ensureKeywordsIsMutable();
keywords_.add(m);
} else {
keywordsBuilder_.addMessage(m);
}
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private int adGroupType_ = 0;
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the adGroupType field is set.
*/
@java.lang.Override public boolean hasAdGroupType() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @return The enum numeric value on the wire for adGroupType.
*/
@java.lang.Override public int getAdGroupTypeValue() {
return adGroupType_;
}
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @param value The enum numeric value on the wire for adGroupType to set.
* @return This builder for chaining.
*/
public Builder setAdGroupTypeValue(int value) {
adGroupType_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @return The adGroupType.
*/
@java.lang.Override
public com.google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType getAdGroupType() {
com.google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType result = com.google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType.forNumber(adGroupType_);
return result == null ? com.google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType.UNRECOGNIZED : result;
}
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @param value The adGroupType to set.
* @return This builder for chaining.
*/
public Builder setAdGroupType(com.google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000001;
adGroupType_ = value.getNumber();
onChanged();
return this;
}
/**
*
* Optional. AdGroup Type of the AdGroup.
* This field is necessary for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.enums.AdGroupTypeEnum.AdGroupType ad_group_type = 1 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearAdGroupType() {
bitField0_ = (bitField0_ & ~0x00000001);
adGroupType_ = 0;
onChanged();
return this;
}
private java.util.List keywords_ =
java.util.Collections.emptyList();
private void ensureKeywordsIsMutable() {
if (!((bitField0_ & 0x00000002) != 0)) {
keywords_ = new java.util.ArrayList(keywords_);
bitField0_ |= 0x00000002;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v18.common.KeywordInfo, com.google.ads.googleads.v18.common.KeywordInfo.Builder, com.google.ads.googleads.v18.common.KeywordInfoOrBuilder> keywordsBuilder_;
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public java.util.List getKeywordsList() {
if (keywordsBuilder_ == null) {
return java.util.Collections.unmodifiableList(keywords_);
} else {
return keywordsBuilder_.getMessageList();
}
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public int getKeywordsCount() {
if (keywordsBuilder_ == null) {
return keywords_.size();
} else {
return keywordsBuilder_.getCount();
}
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.common.KeywordInfo getKeywords(int index) {
if (keywordsBuilder_ == null) {
return keywords_.get(index);
} else {
return keywordsBuilder_.getMessage(index);
}
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setKeywords(
int index, com.google.ads.googleads.v18.common.KeywordInfo value) {
if (keywordsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureKeywordsIsMutable();
keywords_.set(index, value);
onChanged();
} else {
keywordsBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setKeywords(
int index, com.google.ads.googleads.v18.common.KeywordInfo.Builder builderForValue) {
if (keywordsBuilder_ == null) {
ensureKeywordsIsMutable();
keywords_.set(index, builderForValue.build());
onChanged();
} else {
keywordsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addKeywords(com.google.ads.googleads.v18.common.KeywordInfo value) {
if (keywordsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureKeywordsIsMutable();
keywords_.add(value);
onChanged();
} else {
keywordsBuilder_.addMessage(value);
}
return this;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addKeywords(
int index, com.google.ads.googleads.v18.common.KeywordInfo value) {
if (keywordsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureKeywordsIsMutable();
keywords_.add(index, value);
onChanged();
} else {
keywordsBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addKeywords(
com.google.ads.googleads.v18.common.KeywordInfo.Builder builderForValue) {
if (keywordsBuilder_ == null) {
ensureKeywordsIsMutable();
keywords_.add(builderForValue.build());
onChanged();
} else {
keywordsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addKeywords(
int index, com.google.ads.googleads.v18.common.KeywordInfo.Builder builderForValue) {
if (keywordsBuilder_ == null) {
ensureKeywordsIsMutable();
keywords_.add(index, builderForValue.build());
onChanged();
} else {
keywordsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAllKeywords(
java.lang.Iterable extends com.google.ads.googleads.v18.common.KeywordInfo> values) {
if (keywordsBuilder_ == null) {
ensureKeywordsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, keywords_);
onChanged();
} else {
keywordsBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder clearKeywords() {
if (keywordsBuilder_ == null) {
keywords_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
keywordsBuilder_.clear();
}
return this;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder removeKeywords(int index) {
if (keywordsBuilder_ == null) {
ensureKeywordsIsMutable();
keywords_.remove(index);
onChanged();
} else {
keywordsBuilder_.remove(index);
}
return this;
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.common.KeywordInfo.Builder getKeywordsBuilder(
int index) {
return getKeywordsFieldBuilder().getBuilder(index);
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.common.KeywordInfoOrBuilder getKeywordsOrBuilder(
int index) {
if (keywordsBuilder_ == null) {
return keywords_.get(index); } else {
return keywordsBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public java.util.List extends com.google.ads.googleads.v18.common.KeywordInfoOrBuilder>
getKeywordsOrBuilderList() {
if (keywordsBuilder_ != null) {
return keywordsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(keywords_);
}
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.common.KeywordInfo.Builder addKeywordsBuilder() {
return getKeywordsFieldBuilder().addBuilder(
com.google.ads.googleads.v18.common.KeywordInfo.getDefaultInstance());
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.common.KeywordInfo.Builder addKeywordsBuilder(
int index) {
return getKeywordsFieldBuilder().addBuilder(
index, com.google.ads.googleads.v18.common.KeywordInfo.getDefaultInstance());
}
/**
*
* Optional. Current keywords.
* This field is optional for the following recommendation_types if
* ad_group_info is set:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.common.KeywordInfo keywords = 2 [(.google.api.field_behavior) = OPTIONAL];
*/
public java.util.List
getKeywordsBuilderList() {
return getKeywordsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v18.common.KeywordInfo, com.google.ads.googleads.v18.common.KeywordInfo.Builder, com.google.ads.googleads.v18.common.KeywordInfoOrBuilder>
getKeywordsFieldBuilder() {
if (keywordsBuilder_ == null) {
keywordsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v18.common.KeywordInfo, com.google.ads.googleads.v18.common.KeywordInfo.Builder, com.google.ads.googleads.v18.common.KeywordInfoOrBuilder>(
keywords_,
((bitField0_ & 0x00000002) != 0),
getParentForChildren(),
isClean());
keywords_ = null;
}
return keywordsBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo)
}
// @@protoc_insertion_point(class_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo)
private static final com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo();
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public AdGroupInfo parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface SeedInfoOrBuilder extends
// @@protoc_insertion_point(interface_extends:google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo)
com.google.protobuf.MessageOrBuilder {
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @return Whether the urlSeed field is set.
*/
boolean hasUrlSeed();
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @return The urlSeed.
*/
java.lang.String getUrlSeed();
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @return The bytes for urlSeed.
*/
com.google.protobuf.ByteString
getUrlSeedBytes();
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the keywordSeeds.
*/
java.util.List
getKeywordSeedsList();
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of keywordSeeds.
*/
int getKeywordSeedsCount();
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The keywordSeeds at the given index.
*/
java.lang.String getKeywordSeeds(int index);
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the keywordSeeds at the given index.
*/
com.google.protobuf.ByteString
getKeywordSeedsBytes(int index);
}
/**
*
* A keyword seed and a specific url to generate keywords from.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo}
*/
public static final class SeedInfo extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo)
SeedInfoOrBuilder {
private static final long serialVersionUID = 0L;
// Use SeedInfo.newBuilder() to construct.
private SeedInfo(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private SeedInfo() {
urlSeed_ = "";
keywordSeeds_ =
com.google.protobuf.LazyStringArrayList.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new SeedInfo();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_SeedInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_SeedInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.Builder.class);
}
private int bitField0_;
public static final int URL_SEED_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private volatile java.lang.Object urlSeed_ = "";
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @return Whether the urlSeed field is set.
*/
@java.lang.Override
public boolean hasUrlSeed() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @return The urlSeed.
*/
@java.lang.Override
public java.lang.String getUrlSeed() {
java.lang.Object ref = urlSeed_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
urlSeed_ = s;
return s;
}
}
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @return The bytes for urlSeed.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getUrlSeedBytes() {
java.lang.Object ref = urlSeed_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
urlSeed_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int KEYWORD_SEEDS_FIELD_NUMBER = 3;
@SuppressWarnings("serial")
private com.google.protobuf.LazyStringArrayList keywordSeeds_ =
com.google.protobuf.LazyStringArrayList.emptyList();
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the keywordSeeds.
*/
public com.google.protobuf.ProtocolStringList
getKeywordSeedsList() {
return keywordSeeds_;
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of keywordSeeds.
*/
public int getKeywordSeedsCount() {
return keywordSeeds_.size();
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The keywordSeeds at the given index.
*/
public java.lang.String getKeywordSeeds(int index) {
return keywordSeeds_.get(index);
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the keywordSeeds at the given index.
*/
public com.google.protobuf.ByteString
getKeywordSeedsBytes(int index) {
return keywordSeeds_.getByteString(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, urlSeed_);
}
for (int i = 0; i < keywordSeeds_.size(); i++) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, keywordSeeds_.getRaw(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, urlSeed_);
}
{
int dataSize = 0;
for (int i = 0; i < keywordSeeds_.size(); i++) {
dataSize += computeStringSizeNoTag(keywordSeeds_.getRaw(i));
}
size += dataSize;
size += 1 * getKeywordSeedsList().size();
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo)) {
return super.equals(obj);
}
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo other = (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo) obj;
if (hasUrlSeed() != other.hasUrlSeed()) return false;
if (hasUrlSeed()) {
if (!getUrlSeed()
.equals(other.getUrlSeed())) return false;
}
if (!getKeywordSeedsList()
.equals(other.getKeywordSeedsList())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasUrlSeed()) {
hash = (37 * hash) + URL_SEED_FIELD_NUMBER;
hash = (53 * hash) + getUrlSeed().hashCode();
}
if (getKeywordSeedsCount() > 0) {
hash = (37 * hash) + KEYWORD_SEEDS_FIELD_NUMBER;
hash = (53 * hash) + getKeywordSeedsList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* A keyword seed and a specific url to generate keywords from.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo)
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfoOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_SeedInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_SeedInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.Builder.class);
}
// Construct using com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
urlSeed_ = "";
keywordSeeds_ =
com.google.protobuf.LazyStringArrayList.emptyList();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_SeedInfo_descriptor;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo getDefaultInstanceForType() {
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.getDefaultInstance();
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo build() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo buildPartial() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo result = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.urlSeed_ = urlSeed_;
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
keywordSeeds_.makeImmutable();
result.keywordSeeds_ = keywordSeeds_;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo) {
return mergeFrom((com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo other) {
if (other == com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.getDefaultInstance()) return this;
if (other.hasUrlSeed()) {
urlSeed_ = other.urlSeed_;
bitField0_ |= 0x00000001;
onChanged();
}
if (!other.keywordSeeds_.isEmpty()) {
if (keywordSeeds_.isEmpty()) {
keywordSeeds_ = other.keywordSeeds_;
bitField0_ |= 0x00000002;
} else {
ensureKeywordSeedsIsMutable();
keywordSeeds_.addAll(other.keywordSeeds_);
}
onChanged();
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 18: {
urlSeed_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 18
case 26: {
java.lang.String s = input.readStringRequireUtf8();
ensureKeywordSeedsIsMutable();
keywordSeeds_.add(s);
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object urlSeed_ = "";
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @return Whether the urlSeed field is set.
*/
public boolean hasUrlSeed() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @return The urlSeed.
*/
public java.lang.String getUrlSeed() {
java.lang.Object ref = urlSeed_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
urlSeed_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @return The bytes for urlSeed.
*/
public com.google.protobuf.ByteString
getUrlSeedBytes() {
java.lang.Object ref = urlSeed_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
urlSeed_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @param value The urlSeed to set.
* @return This builder for chaining.
*/
public Builder setUrlSeed(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
urlSeed_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @return This builder for chaining.
*/
public Builder clearUrlSeed() {
urlSeed_ = getDefaultInstance().getUrlSeed();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* A specific url to generate ideas from, for example: www.example.com/cars.
*
*
* optional string url_seed = 2;
* @param value The bytes for urlSeed to set.
* @return This builder for chaining.
*/
public Builder setUrlSeedBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
urlSeed_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private com.google.protobuf.LazyStringArrayList keywordSeeds_ =
com.google.protobuf.LazyStringArrayList.emptyList();
private void ensureKeywordSeedsIsMutable() {
if (!keywordSeeds_.isModifiable()) {
keywordSeeds_ = new com.google.protobuf.LazyStringArrayList(keywordSeeds_);
}
bitField0_ |= 0x00000002;
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the keywordSeeds.
*/
public com.google.protobuf.ProtocolStringList
getKeywordSeedsList() {
keywordSeeds_.makeImmutable();
return keywordSeeds_;
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of keywordSeeds.
*/
public int getKeywordSeedsCount() {
return keywordSeeds_.size();
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The keywordSeeds at the given index.
*/
public java.lang.String getKeywordSeeds(int index) {
return keywordSeeds_.get(index);
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the keywordSeeds at the given index.
*/
public com.google.protobuf.ByteString
getKeywordSeedsBytes(int index) {
return keywordSeeds_.getByteString(index);
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index to set the value at.
* @param value The keywordSeeds to set.
* @return This builder for chaining.
*/
public Builder setKeywordSeeds(
int index, java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureKeywordSeedsIsMutable();
keywordSeeds_.set(index, value);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param value The keywordSeeds to add.
* @return This builder for chaining.
*/
public Builder addKeywordSeeds(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureKeywordSeedsIsMutable();
keywordSeeds_.add(value);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param values The keywordSeeds to add.
* @return This builder for chaining.
*/
public Builder addAllKeywordSeeds(
java.lang.Iterable values) {
ensureKeywordSeedsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, keywordSeeds_);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearKeywordSeeds() {
keywordSeeds_ =
com.google.protobuf.LazyStringArrayList.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);;
onChanged();
return this;
}
/**
*
* Optional. Keywords or phrases to generate ideas from, for example: cars
* or "car dealership near me".
*
*
* repeated string keyword_seeds = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param value The bytes of the keywordSeeds to add.
* @return This builder for chaining.
*/
public Builder addKeywordSeedsBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
ensureKeywordSeedsIsMutable();
keywordSeeds_.add(value);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo)
}
// @@protoc_insertion_point(class_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo)
private static final com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo();
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public SeedInfo parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface BudgetInfoOrBuilder extends
// @@protoc_insertion_point(interface_extends:google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo)
com.google.protobuf.MessageOrBuilder {
/**
*
* Required. Current budget amount.
* This field is necessary for the following recommendation_types if
* budget_info is set:
* CAMPAIGN_BUDGET
*
*
* optional int64 current_budget = 1 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the currentBudget field is set.
*/
boolean hasCurrentBudget();
/**
*
* Required. Current budget amount.
* This field is necessary for the following recommendation_types if
* budget_info is set:
* CAMPAIGN_BUDGET
*
*
* optional int64 current_budget = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The currentBudget.
*/
long getCurrentBudget();
}
/**
*
* Current budget information of the campaign.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo}
*/
public static final class BudgetInfo extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo)
BudgetInfoOrBuilder {
private static final long serialVersionUID = 0L;
// Use BudgetInfo.newBuilder() to construct.
private BudgetInfo(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private BudgetInfo() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new BudgetInfo();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_BudgetInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_BudgetInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.Builder.class);
}
private int bitField0_;
public static final int CURRENT_BUDGET_FIELD_NUMBER = 1;
private long currentBudget_ = 0L;
/**
*
* Required. Current budget amount.
* This field is necessary for the following recommendation_types if
* budget_info is set:
* CAMPAIGN_BUDGET
*
*
* optional int64 current_budget = 1 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the currentBudget field is set.
*/
@java.lang.Override
public boolean hasCurrentBudget() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Required. Current budget amount.
* This field is necessary for the following recommendation_types if
* budget_info is set:
* CAMPAIGN_BUDGET
*
*
* optional int64 current_budget = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The currentBudget.
*/
@java.lang.Override
public long getCurrentBudget() {
return currentBudget_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
output.writeInt64(1, currentBudget_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(1, currentBudget_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo)) {
return super.equals(obj);
}
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo other = (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo) obj;
if (hasCurrentBudget() != other.hasCurrentBudget()) return false;
if (hasCurrentBudget()) {
if (getCurrentBudget()
!= other.getCurrentBudget()) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasCurrentBudget()) {
hash = (37 * hash) + CURRENT_BUDGET_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getCurrentBudget());
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Current budget information of the campaign.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo)
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfoOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_BudgetInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_BudgetInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.Builder.class);
}
// Construct using com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
currentBudget_ = 0L;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_BudgetInfo_descriptor;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo getDefaultInstanceForType() {
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.getDefaultInstance();
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo build() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo buildPartial() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo result = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.currentBudget_ = currentBudget_;
to_bitField0_ |= 0x00000001;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo) {
return mergeFrom((com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo other) {
if (other == com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.getDefaultInstance()) return this;
if (other.hasCurrentBudget()) {
setCurrentBudget(other.getCurrentBudget());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
currentBudget_ = input.readInt64();
bitField0_ |= 0x00000001;
break;
} // case 8
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private long currentBudget_ ;
/**
*
* Required. Current budget amount.
* This field is necessary for the following recommendation_types if
* budget_info is set:
* CAMPAIGN_BUDGET
*
*
* optional int64 current_budget = 1 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the currentBudget field is set.
*/
@java.lang.Override
public boolean hasCurrentBudget() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Required. Current budget amount.
* This field is necessary for the following recommendation_types if
* budget_info is set:
* CAMPAIGN_BUDGET
*
*
* optional int64 current_budget = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The currentBudget.
*/
@java.lang.Override
public long getCurrentBudget() {
return currentBudget_;
}
/**
*
* Required. Current budget amount.
* This field is necessary for the following recommendation_types if
* budget_info is set:
* CAMPAIGN_BUDGET
*
*
* optional int64 current_budget = 1 [(.google.api.field_behavior) = REQUIRED];
* @param value The currentBudget to set.
* @return This builder for chaining.
*/
public Builder setCurrentBudget(long value) {
currentBudget_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Required. Current budget amount.
* This field is necessary for the following recommendation_types if
* budget_info is set:
* CAMPAIGN_BUDGET
*
*
* optional int64 current_budget = 1 [(.google.api.field_behavior) = REQUIRED];
* @return This builder for chaining.
*/
public Builder clearCurrentBudget() {
bitField0_ = (bitField0_ & ~0x00000001);
currentBudget_ = 0L;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo)
}
// @@protoc_insertion_point(class_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo)
private static final com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo();
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public BudgetInfo parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface AssetGroupInfoOrBuilder extends
// @@protoc_insertion_point(interface_extends:google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo)
com.google.protobuf.MessageOrBuilder {
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the finalUrl field is set.
*/
boolean hasFinalUrl();
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The finalUrl.
*/
java.lang.String getFinalUrl();
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The bytes for finalUrl.
*/
com.google.protobuf.ByteString
getFinalUrlBytes();
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the headline.
*/
java.util.List
getHeadlineList();
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of headline.
*/
int getHeadlineCount();
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The headline at the given index.
*/
java.lang.String getHeadline(int index);
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the headline at the given index.
*/
com.google.protobuf.ByteString
getHeadlineBytes(int index);
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the description.
*/
java.util.List
getDescriptionList();
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of description.
*/
int getDescriptionCount();
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The description at the given index.
*/
java.lang.String getDescription(int index);
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the description at the given index.
*/
com.google.protobuf.ByteString
getDescriptionBytes(int index);
}
/**
*
* Current AssetGroup information of the campaign.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo}
*/
public static final class AssetGroupInfo extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo)
AssetGroupInfoOrBuilder {
private static final long serialVersionUID = 0L;
// Use AssetGroupInfo.newBuilder() to construct.
private AssetGroupInfo(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private AssetGroupInfo() {
finalUrl_ = "";
headline_ =
com.google.protobuf.LazyStringArrayList.emptyList();
description_ =
com.google.protobuf.LazyStringArrayList.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new AssetGroupInfo();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_AssetGroupInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_AssetGroupInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder.class);
}
private int bitField0_;
public static final int FINAL_URL_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object finalUrl_ = "";
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the finalUrl field is set.
*/
@java.lang.Override
public boolean hasFinalUrl() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The finalUrl.
*/
@java.lang.Override
public java.lang.String getFinalUrl() {
java.lang.Object ref = finalUrl_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
finalUrl_ = s;
return s;
}
}
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The bytes for finalUrl.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getFinalUrlBytes() {
java.lang.Object ref = finalUrl_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
finalUrl_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int HEADLINE_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private com.google.protobuf.LazyStringArrayList headline_ =
com.google.protobuf.LazyStringArrayList.emptyList();
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the headline.
*/
public com.google.protobuf.ProtocolStringList
getHeadlineList() {
return headline_;
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of headline.
*/
public int getHeadlineCount() {
return headline_.size();
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The headline at the given index.
*/
public java.lang.String getHeadline(int index) {
return headline_.get(index);
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the headline at the given index.
*/
public com.google.protobuf.ByteString
getHeadlineBytes(int index) {
return headline_.getByteString(index);
}
public static final int DESCRIPTION_FIELD_NUMBER = 3;
@SuppressWarnings("serial")
private com.google.protobuf.LazyStringArrayList description_ =
com.google.protobuf.LazyStringArrayList.emptyList();
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the description.
*/
public com.google.protobuf.ProtocolStringList
getDescriptionList() {
return description_;
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of description.
*/
public int getDescriptionCount() {
return description_.size();
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The description at the given index.
*/
public java.lang.String getDescription(int index) {
return description_.get(index);
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the description at the given index.
*/
public com.google.protobuf.ByteString
getDescriptionBytes(int index) {
return description_.getByteString(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, finalUrl_);
}
for (int i = 0; i < headline_.size(); i++) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 2, headline_.getRaw(i));
}
for (int i = 0; i < description_.size(); i++) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 3, description_.getRaw(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, finalUrl_);
}
{
int dataSize = 0;
for (int i = 0; i < headline_.size(); i++) {
dataSize += computeStringSizeNoTag(headline_.getRaw(i));
}
size += dataSize;
size += 1 * getHeadlineList().size();
}
{
int dataSize = 0;
for (int i = 0; i < description_.size(); i++) {
dataSize += computeStringSizeNoTag(description_.getRaw(i));
}
size += dataSize;
size += 1 * getDescriptionList().size();
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo)) {
return super.equals(obj);
}
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo other = (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo) obj;
if (hasFinalUrl() != other.hasFinalUrl()) return false;
if (hasFinalUrl()) {
if (!getFinalUrl()
.equals(other.getFinalUrl())) return false;
}
if (!getHeadlineList()
.equals(other.getHeadlineList())) return false;
if (!getDescriptionList()
.equals(other.getDescriptionList())) return false;
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasFinalUrl()) {
hash = (37 * hash) + FINAL_URL_FIELD_NUMBER;
hash = (53 * hash) + getFinalUrl().hashCode();
}
if (getHeadlineCount() > 0) {
hash = (37 * hash) + HEADLINE_FIELD_NUMBER;
hash = (53 * hash) + getHeadlineList().hashCode();
}
if (getDescriptionCount() > 0) {
hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER;
hash = (53 * hash) + getDescriptionList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Current AssetGroup information of the campaign.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo)
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfoOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_AssetGroupInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_AssetGroupInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder.class);
}
// Construct using com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
finalUrl_ = "";
headline_ =
com.google.protobuf.LazyStringArrayList.emptyList();
description_ =
com.google.protobuf.LazyStringArrayList.emptyList();
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_AssetGroupInfo_descriptor;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo getDefaultInstanceForType() {
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.getDefaultInstance();
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo build() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo buildPartial() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo result = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.finalUrl_ = finalUrl_;
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
headline_.makeImmutable();
result.headline_ = headline_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
description_.makeImmutable();
result.description_ = description_;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo) {
return mergeFrom((com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo other) {
if (other == com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.getDefaultInstance()) return this;
if (other.hasFinalUrl()) {
finalUrl_ = other.finalUrl_;
bitField0_ |= 0x00000001;
onChanged();
}
if (!other.headline_.isEmpty()) {
if (headline_.isEmpty()) {
headline_ = other.headline_;
bitField0_ |= 0x00000002;
} else {
ensureHeadlineIsMutable();
headline_.addAll(other.headline_);
}
onChanged();
}
if (!other.description_.isEmpty()) {
if (description_.isEmpty()) {
description_ = other.description_;
bitField0_ |= 0x00000004;
} else {
ensureDescriptionIsMutable();
description_.addAll(other.description_);
}
onChanged();
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
finalUrl_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
java.lang.String s = input.readStringRequireUtf8();
ensureHeadlineIsMutable();
headline_.add(s);
break;
} // case 18
case 26: {
java.lang.String s = input.readStringRequireUtf8();
ensureDescriptionIsMutable();
description_.add(s);
break;
} // case 26
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object finalUrl_ = "";
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the finalUrl field is set.
*/
public boolean hasFinalUrl() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The finalUrl.
*/
public java.lang.String getFinalUrl() {
java.lang.Object ref = finalUrl_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
finalUrl_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The bytes for finalUrl.
*/
public com.google.protobuf.ByteString
getFinalUrlBytes() {
java.lang.Object ref = finalUrl_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
finalUrl_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @param value The finalUrl to set.
* @return This builder for chaining.
*/
public Builder setFinalUrl(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
finalUrl_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @return This builder for chaining.
*/
public Builder clearFinalUrl() {
finalUrl_ = getDefaultInstance().getFinalUrl();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* Required. Current url of the asset group.
* This field is necessary for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* optional string final_url = 1 [(.google.api.field_behavior) = REQUIRED];
* @param value The bytes for finalUrl to set.
* @return This builder for chaining.
*/
public Builder setFinalUrlBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
finalUrl_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private com.google.protobuf.LazyStringArrayList headline_ =
com.google.protobuf.LazyStringArrayList.emptyList();
private void ensureHeadlineIsMutable() {
if (!headline_.isModifiable()) {
headline_ = new com.google.protobuf.LazyStringArrayList(headline_);
}
bitField0_ |= 0x00000002;
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the headline.
*/
public com.google.protobuf.ProtocolStringList
getHeadlineList() {
headline_.makeImmutable();
return headline_;
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of headline.
*/
public int getHeadlineCount() {
return headline_.size();
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The headline at the given index.
*/
public java.lang.String getHeadline(int index) {
return headline_.get(index);
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the headline at the given index.
*/
public com.google.protobuf.ByteString
getHeadlineBytes(int index) {
return headline_.getByteString(index);
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index to set the value at.
* @param value The headline to set.
* @return This builder for chaining.
*/
public Builder setHeadline(
int index, java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureHeadlineIsMutable();
headline_.set(index, value);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @param value The headline to add.
* @return This builder for chaining.
*/
public Builder addHeadline(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureHeadlineIsMutable();
headline_.add(value);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @param values The headline to add.
* @return This builder for chaining.
*/
public Builder addAllHeadline(
java.lang.Iterable values) {
ensureHeadlineIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, headline_);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearHeadline() {
headline_ =
com.google.protobuf.LazyStringArrayList.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);;
onChanged();
return this;
}
/**
*
* Optional. Current headlines of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string headline = 2 [(.google.api.field_behavior) = OPTIONAL];
* @param value The bytes of the headline to add.
* @return This builder for chaining.
*/
public Builder addHeadlineBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
ensureHeadlineIsMutable();
headline_.add(value);
bitField0_ |= 0x00000002;
onChanged();
return this;
}
private com.google.protobuf.LazyStringArrayList description_ =
com.google.protobuf.LazyStringArrayList.emptyList();
private void ensureDescriptionIsMutable() {
if (!description_.isModifiable()) {
description_ = new com.google.protobuf.LazyStringArrayList(description_);
}
bitField0_ |= 0x00000004;
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the description.
*/
public com.google.protobuf.ProtocolStringList
getDescriptionList() {
description_.makeImmutable();
return description_;
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of description.
*/
public int getDescriptionCount() {
return description_.size();
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The description at the given index.
*/
public java.lang.String getDescription(int index) {
return description_.get(index);
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the description at the given index.
*/
public com.google.protobuf.ByteString
getDescriptionBytes(int index) {
return description_.getByteString(index);
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index to set the value at.
* @param value The description to set.
* @return This builder for chaining.
*/
public Builder setDescription(
int index, java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureDescriptionIsMutable();
description_.set(index, value);
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param value The description to add.
* @return This builder for chaining.
*/
public Builder addDescription(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureDescriptionIsMutable();
description_.add(value);
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param values The description to add.
* @return This builder for chaining.
*/
public Builder addAllDescription(
java.lang.Iterable values) {
ensureDescriptionIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, description_);
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearDescription() {
description_ =
com.google.protobuf.LazyStringArrayList.emptyList();
bitField0_ = (bitField0_ & ~0x00000004);;
onChanged();
return this;
}
/**
*
* Optional. Current descriptions of the asset group.
* This field is optional for the following recommendation_types if
* asset_group_info is set:
* CAMPAIGN_BUDGET
*
*
* repeated string description = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param value The bytes of the description to add.
* @return This builder for chaining.
*/
public Builder addDescriptionBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
ensureDescriptionIsMutable();
description_.add(value);
bitField0_ |= 0x00000004;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo)
}
// @@protoc_insertion_point(class_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo)
private static final com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo();
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public AssetGroupInfo parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface TargetImpressionShareInfoOrBuilder extends
// @@protoc_insertion_point(interface_extends:google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo)
com.google.protobuf.MessageOrBuilder {
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the location field is set.
*/
boolean hasLocation();
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The enum numeric value on the wire for location.
*/
int getLocationValue();
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The location.
*/
com.google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation getLocation();
/**
*
* Required. The chosen fraction of targeted impression share in micros. For
* example, 1% equals 10,000. It must be a value between 1 and 1,000,000.
* This is required for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 target_impression_share_micros = 2 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the targetImpressionShareMicros field is set.
*/
boolean hasTargetImpressionShareMicros();
/**
*
* Required. The chosen fraction of targeted impression share in micros. For
* example, 1% equals 10,000. It must be a value between 1 and 1,000,000.
* This is required for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 target_impression_share_micros = 2 [(.google.api.field_behavior) = REQUIRED];
* @return The targetImpressionShareMicros.
*/
long getTargetImpressionShareMicros();
/**
*
* Optional. Ceiling of max CPC bids in micros set by automated bidders.
* This is optional for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 max_cpc_bid_ceiling = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the maxCpcBidCeiling field is set.
*/
boolean hasMaxCpcBidCeiling();
/**
*
* Optional. Ceiling of max CPC bids in micros set by automated bidders.
* This is optional for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 max_cpc_bid_ceiling = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return The maxCpcBidCeiling.
*/
long getMaxCpcBidCeiling();
}
/**
*
* Current Target Impression Share information of the campaign.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo}
*/
public static final class TargetImpressionShareInfo extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo)
TargetImpressionShareInfoOrBuilder {
private static final long serialVersionUID = 0L;
// Use TargetImpressionShareInfo.newBuilder() to construct.
private TargetImpressionShareInfo(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private TargetImpressionShareInfo() {
location_ = 0;
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new TargetImpressionShareInfo();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_TargetImpressionShareInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_TargetImpressionShareInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.Builder.class);
}
private int bitField0_;
public static final int LOCATION_FIELD_NUMBER = 1;
private int location_ = 0;
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the location field is set.
*/
@java.lang.Override public boolean hasLocation() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The enum numeric value on the wire for location.
*/
@java.lang.Override public int getLocationValue() {
return location_;
}
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The location.
*/
@java.lang.Override public com.google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation getLocation() {
com.google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation result = com.google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation.forNumber(location_);
return result == null ? com.google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation.UNRECOGNIZED : result;
}
public static final int TARGET_IMPRESSION_SHARE_MICROS_FIELD_NUMBER = 2;
private long targetImpressionShareMicros_ = 0L;
/**
*
* Required. The chosen fraction of targeted impression share in micros. For
* example, 1% equals 10,000. It must be a value between 1 and 1,000,000.
* This is required for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 target_impression_share_micros = 2 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the targetImpressionShareMicros field is set.
*/
@java.lang.Override
public boolean hasTargetImpressionShareMicros() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Required. The chosen fraction of targeted impression share in micros. For
* example, 1% equals 10,000. It must be a value between 1 and 1,000,000.
* This is required for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 target_impression_share_micros = 2 [(.google.api.field_behavior) = REQUIRED];
* @return The targetImpressionShareMicros.
*/
@java.lang.Override
public long getTargetImpressionShareMicros() {
return targetImpressionShareMicros_;
}
public static final int MAX_CPC_BID_CEILING_FIELD_NUMBER = 3;
private long maxCpcBidCeiling_ = 0L;
/**
*
* Optional. Ceiling of max CPC bids in micros set by automated bidders.
* This is optional for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 max_cpc_bid_ceiling = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the maxCpcBidCeiling field is set.
*/
@java.lang.Override
public boolean hasMaxCpcBidCeiling() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Optional. Ceiling of max CPC bids in micros set by automated bidders.
* This is optional for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 max_cpc_bid_ceiling = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return The maxCpcBidCeiling.
*/
@java.lang.Override
public long getMaxCpcBidCeiling() {
return maxCpcBidCeiling_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
output.writeEnum(1, location_);
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeInt64(2, targetImpressionShareMicros_);
}
if (((bitField0_ & 0x00000004) != 0)) {
output.writeInt64(3, maxCpcBidCeiling_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(1, location_);
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(2, targetImpressionShareMicros_);
}
if (((bitField0_ & 0x00000004) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeInt64Size(3, maxCpcBidCeiling_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo)) {
return super.equals(obj);
}
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo other = (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo) obj;
if (hasLocation() != other.hasLocation()) return false;
if (hasLocation()) {
if (location_ != other.location_) return false;
}
if (hasTargetImpressionShareMicros() != other.hasTargetImpressionShareMicros()) return false;
if (hasTargetImpressionShareMicros()) {
if (getTargetImpressionShareMicros()
!= other.getTargetImpressionShareMicros()) return false;
}
if (hasMaxCpcBidCeiling() != other.hasMaxCpcBidCeiling()) return false;
if (hasMaxCpcBidCeiling()) {
if (getMaxCpcBidCeiling()
!= other.getMaxCpcBidCeiling()) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasLocation()) {
hash = (37 * hash) + LOCATION_FIELD_NUMBER;
hash = (53 * hash) + location_;
}
if (hasTargetImpressionShareMicros()) {
hash = (37 * hash) + TARGET_IMPRESSION_SHARE_MICROS_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getTargetImpressionShareMicros());
}
if (hasMaxCpcBidCeiling()) {
hash = (37 * hash) + MAX_CPC_BID_CEILING_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
getMaxCpcBidCeiling());
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Current Target Impression Share information of the campaign.
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo)
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfoOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_TargetImpressionShareInfo_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_TargetImpressionShareInfo_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.Builder.class);
}
// Construct using com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
location_ = 0;
targetImpressionShareMicros_ = 0L;
maxCpcBidCeiling_ = 0L;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_TargetImpressionShareInfo_descriptor;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo getDefaultInstanceForType() {
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.getDefaultInstance();
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo build() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo buildPartial() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo result = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo(this);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartial0(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.location_ = location_;
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000002) != 0)) {
result.targetImpressionShareMicros_ = targetImpressionShareMicros_;
to_bitField0_ |= 0x00000002;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.maxCpcBidCeiling_ = maxCpcBidCeiling_;
to_bitField0_ |= 0x00000004;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo) {
return mergeFrom((com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo other) {
if (other == com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo.getDefaultInstance()) return this;
if (other.hasLocation()) {
setLocation(other.getLocation());
}
if (other.hasTargetImpressionShareMicros()) {
setTargetImpressionShareMicros(other.getTargetImpressionShareMicros());
}
if (other.hasMaxCpcBidCeiling()) {
setMaxCpcBidCeiling(other.getMaxCpcBidCeiling());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 8: {
location_ = input.readEnum();
bitField0_ |= 0x00000001;
break;
} // case 8
case 16: {
targetImpressionShareMicros_ = input.readInt64();
bitField0_ |= 0x00000002;
break;
} // case 16
case 24: {
maxCpcBidCeiling_ = input.readInt64();
bitField0_ |= 0x00000004;
break;
} // case 24
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private int location_ = 0;
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the location field is set.
*/
@java.lang.Override public boolean hasLocation() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The enum numeric value on the wire for location.
*/
@java.lang.Override public int getLocationValue() {
return location_;
}
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @param value The enum numeric value on the wire for location to set.
* @return This builder for chaining.
*/
public Builder setLocationValue(int value) {
location_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The location.
*/
@java.lang.Override
public com.google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation getLocation() {
com.google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation result = com.google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation.forNumber(location_);
return result == null ? com.google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation.UNRECOGNIZED : result;
}
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @param value The location to set.
* @return This builder for chaining.
*/
public Builder setLocation(com.google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000001;
location_ = value.getNumber();
onChanged();
return this;
}
/**
*
* Required. The targeted location on the search results page.
* This is required for campaigns where the AdvertisingChannelType is SEARCH
* and the bidding strategy type is TARGET_IMPRESSION_SHARE.
*
*
* optional .google.ads.googleads.v18.enums.TargetImpressionShareLocationEnum.TargetImpressionShareLocation location = 1 [(.google.api.field_behavior) = REQUIRED];
* @return This builder for chaining.
*/
public Builder clearLocation() {
bitField0_ = (bitField0_ & ~0x00000001);
location_ = 0;
onChanged();
return this;
}
private long targetImpressionShareMicros_ ;
/**
*
* Required. The chosen fraction of targeted impression share in micros. For
* example, 1% equals 10,000. It must be a value between 1 and 1,000,000.
* This is required for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 target_impression_share_micros = 2 [(.google.api.field_behavior) = REQUIRED];
* @return Whether the targetImpressionShareMicros field is set.
*/
@java.lang.Override
public boolean hasTargetImpressionShareMicros() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Required. The chosen fraction of targeted impression share in micros. For
* example, 1% equals 10,000. It must be a value between 1 and 1,000,000.
* This is required for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 target_impression_share_micros = 2 [(.google.api.field_behavior) = REQUIRED];
* @return The targetImpressionShareMicros.
*/
@java.lang.Override
public long getTargetImpressionShareMicros() {
return targetImpressionShareMicros_;
}
/**
*
* Required. The chosen fraction of targeted impression share in micros. For
* example, 1% equals 10,000. It must be a value between 1 and 1,000,000.
* This is required for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 target_impression_share_micros = 2 [(.google.api.field_behavior) = REQUIRED];
* @param value The targetImpressionShareMicros to set.
* @return This builder for chaining.
*/
public Builder setTargetImpressionShareMicros(long value) {
targetImpressionShareMicros_ = value;
bitField0_ |= 0x00000002;
onChanged();
return this;
}
/**
*
* Required. The chosen fraction of targeted impression share in micros. For
* example, 1% equals 10,000. It must be a value between 1 and 1,000,000.
* This is required for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 target_impression_share_micros = 2 [(.google.api.field_behavior) = REQUIRED];
* @return This builder for chaining.
*/
public Builder clearTargetImpressionShareMicros() {
bitField0_ = (bitField0_ & ~0x00000002);
targetImpressionShareMicros_ = 0L;
onChanged();
return this;
}
private long maxCpcBidCeiling_ ;
/**
*
* Optional. Ceiling of max CPC bids in micros set by automated bidders.
* This is optional for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 max_cpc_bid_ceiling = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the maxCpcBidCeiling field is set.
*/
@java.lang.Override
public boolean hasMaxCpcBidCeiling() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Optional. Ceiling of max CPC bids in micros set by automated bidders.
* This is optional for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 max_cpc_bid_ceiling = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return The maxCpcBidCeiling.
*/
@java.lang.Override
public long getMaxCpcBidCeiling() {
return maxCpcBidCeiling_;
}
/**
*
* Optional. Ceiling of max CPC bids in micros set by automated bidders.
* This is optional for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 max_cpc_bid_ceiling = 3 [(.google.api.field_behavior) = OPTIONAL];
* @param value The maxCpcBidCeiling to set.
* @return This builder for chaining.
*/
public Builder setMaxCpcBidCeiling(long value) {
maxCpcBidCeiling_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Optional. Ceiling of max CPC bids in micros set by automated bidders.
* This is optional for campaigns with an AdvertisingChannelType of SEARCH
* and a bidding strategy type of TARGET_IMPRESSION_SHARE.
*
*
* optional int64 max_cpc_bid_ceiling = 3 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearMaxCpcBidCeiling() {
bitField0_ = (bitField0_ & ~0x00000004);
maxCpcBidCeiling_ = 0L;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo)
}
// @@protoc_insertion_point(class_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo)
private static final com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo();
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public TargetImpressionShareInfo parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.TargetImpressionShareInfo getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private int bitField0_;
public static final int CUSTOMER_ID_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private volatile java.lang.Object customerId_ = "";
/**
*
* Required. The ID of the customer generating recommendations.
*
*
* string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The customerId.
*/
@java.lang.Override
public java.lang.String getCustomerId() {
java.lang.Object ref = customerId_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
customerId_ = s;
return s;
}
}
/**
*
* Required. The ID of the customer generating recommendations.
*
*
* string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The bytes for customerId.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getCustomerIdBytes() {
java.lang.Object ref = customerId_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
customerId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int RECOMMENDATION_TYPES_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private java.util.List recommendationTypes_;
private static final com.google.protobuf.Internal.ListAdapter.Converter<
java.lang.Integer, com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType> recommendationTypes_converter_ =
new com.google.protobuf.Internal.ListAdapter.Converter<
java.lang.Integer, com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType>() {
public com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType convert(java.lang.Integer from) {
com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType result = com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType.forNumber(from);
return result == null ? com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType.UNRECOGNIZED : result;
}
};
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @return A list containing the recommendationTypes.
*/
@java.lang.Override
public java.util.List getRecommendationTypesList() {
return new com.google.protobuf.Internal.ListAdapter<
java.lang.Integer, com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType>(recommendationTypes_, recommendationTypes_converter_);
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @return The count of recommendationTypes.
*/
@java.lang.Override
public int getRecommendationTypesCount() {
return recommendationTypes_.size();
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @param index The index of the element to return.
* @return The recommendationTypes at the given index.
*/
@java.lang.Override
public com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType getRecommendationTypes(int index) {
return recommendationTypes_converter_.convert(recommendationTypes_.get(index));
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @return A list containing the enum numeric values on the wire for recommendationTypes.
*/
@java.lang.Override
public java.util.List
getRecommendationTypesValueList() {
return recommendationTypes_;
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @param index The index of the value to return.
* @return The enum numeric value on the wire of recommendationTypes at the given index.
*/
@java.lang.Override
public int getRecommendationTypesValue(int index) {
return recommendationTypes_.get(index);
}
private int recommendationTypesMemoizedSerializedSize;
public static final int ADVERTISING_CHANNEL_TYPE_FIELD_NUMBER = 3;
private int advertisingChannelType_ = 0;
/**
*
* Required. Advertising channel type of the campaign.
* The following advertising_channel_types are supported for recommendation
* generation:
* PERFORMANCE_MAX and SEARCH
*
*
* .google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType advertising_channel_type = 3 [(.google.api.field_behavior) = REQUIRED];
* @return The enum numeric value on the wire for advertisingChannelType.
*/
@java.lang.Override public int getAdvertisingChannelTypeValue() {
return advertisingChannelType_;
}
/**
*
* Required. Advertising channel type of the campaign.
* The following advertising_channel_types are supported for recommendation
* generation:
* PERFORMANCE_MAX and SEARCH
*
*
* .google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType advertising_channel_type = 3 [(.google.api.field_behavior) = REQUIRED];
* @return The advertisingChannelType.
*/
@java.lang.Override public com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType getAdvertisingChannelType() {
com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType result = com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType.forNumber(advertisingChannelType_);
return result == null ? com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType.UNRECOGNIZED : result;
}
public static final int CAMPAIGN_SITELINK_COUNT_FIELD_NUMBER = 4;
private int campaignSitelinkCount_ = 0;
/**
*
* Optional. Number of sitelinks on the campaign.
* This field is necessary for the following recommendation_types:
* SITELINK_ASSET
*
*
* optional int32 campaign_sitelink_count = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the campaignSitelinkCount field is set.
*/
@java.lang.Override
public boolean hasCampaignSitelinkCount() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Optional. Number of sitelinks on the campaign.
* This field is necessary for the following recommendation_types:
* SITELINK_ASSET
*
*
* optional int32 campaign_sitelink_count = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return The campaignSitelinkCount.
*/
@java.lang.Override
public int getCampaignSitelinkCount() {
return campaignSitelinkCount_;
}
public static final int CONVERSION_TRACKING_STATUS_FIELD_NUMBER = 5;
private int conversionTrackingStatus_ = 0;
/**
*
* Optional. Current conversion tracking status.
* This field is necessary for the following recommendation_types:
* MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus conversion_tracking_status = 5 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the conversionTrackingStatus field is set.
*/
@java.lang.Override public boolean hasConversionTrackingStatus() {
return ((bitField0_ & 0x00000002) != 0);
}
/**
*
* Optional. Current conversion tracking status.
* This field is necessary for the following recommendation_types:
* MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus conversion_tracking_status = 5 [(.google.api.field_behavior) = OPTIONAL];
* @return The enum numeric value on the wire for conversionTrackingStatus.
*/
@java.lang.Override public int getConversionTrackingStatusValue() {
return conversionTrackingStatus_;
}
/**
*
* Optional. Current conversion tracking status.
* This field is necessary for the following recommendation_types:
* MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus conversion_tracking_status = 5 [(.google.api.field_behavior) = OPTIONAL];
* @return The conversionTrackingStatus.
*/
@java.lang.Override public com.google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus getConversionTrackingStatus() {
com.google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus result = com.google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus.forNumber(conversionTrackingStatus_);
return result == null ? com.google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus.UNRECOGNIZED : result;
}
public static final int BIDDING_INFO_FIELD_NUMBER = 6;
private com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo biddingInfo_;
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the biddingInfo field is set.
*/
@java.lang.Override
public boolean hasBiddingInfo() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
* @return The biddingInfo.
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo getBiddingInfo() {
return biddingInfo_ == null ? com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.getDefaultInstance() : biddingInfo_;
}
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfoOrBuilder getBiddingInfoOrBuilder() {
return biddingInfo_ == null ? com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.getDefaultInstance() : biddingInfo_;
}
public static final int AD_GROUP_INFO_FIELD_NUMBER = 7;
@SuppressWarnings("serial")
private java.util.List adGroupInfo_;
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public java.util.List getAdGroupInfoList() {
return adGroupInfo_;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public java.util.List extends com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfoOrBuilder>
getAdGroupInfoOrBuilderList() {
return adGroupInfo_;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public int getAdGroupInfoCount() {
return adGroupInfo_.size();
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo getAdGroupInfo(int index) {
return adGroupInfo_.get(index);
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfoOrBuilder getAdGroupInfoOrBuilder(
int index) {
return adGroupInfo_.get(index);
}
public static final int SEED_INFO_FIELD_NUMBER = 8;
private com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seedInfo_;
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the seedInfo field is set.
*/
@java.lang.Override
public boolean hasSeedInfo() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
* @return The seedInfo.
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo getSeedInfo() {
return seedInfo_ == null ? com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.getDefaultInstance() : seedInfo_;
}
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfoOrBuilder getSeedInfoOrBuilder() {
return seedInfo_ == null ? com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.getDefaultInstance() : seedInfo_;
}
public static final int BUDGET_INFO_FIELD_NUMBER = 9;
private com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budgetInfo_;
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the budgetInfo field is set.
*/
@java.lang.Override
public boolean hasBudgetInfo() {
return ((bitField0_ & 0x00000010) != 0);
}
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
* @return The budgetInfo.
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo getBudgetInfo() {
return budgetInfo_ == null ? com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.getDefaultInstance() : budgetInfo_;
}
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfoOrBuilder getBudgetInfoOrBuilder() {
return budgetInfo_ == null ? com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.getDefaultInstance() : budgetInfo_;
}
public static final int CAMPAIGN_IMAGE_ASSET_COUNT_FIELD_NUMBER = 10;
private int campaignImageAssetCount_ = 0;
/**
*
* Optional. Current campaign image asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_image_asset_count = 10 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the campaignImageAssetCount field is set.
*/
@java.lang.Override
public boolean hasCampaignImageAssetCount() {
return ((bitField0_ & 0x00000020) != 0);
}
/**
*
* Optional. Current campaign image asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_image_asset_count = 10 [(.google.api.field_behavior) = OPTIONAL];
* @return The campaignImageAssetCount.
*/
@java.lang.Override
public int getCampaignImageAssetCount() {
return campaignImageAssetCount_;
}
public static final int CAMPAIGN_CALL_ASSET_COUNT_FIELD_NUMBER = 11;
private int campaignCallAssetCount_ = 0;
/**
*
* Optional. Current campaign call asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_call_asset_count = 11 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the campaignCallAssetCount field is set.
*/
@java.lang.Override
public boolean hasCampaignCallAssetCount() {
return ((bitField0_ & 0x00000040) != 0);
}
/**
*
* Optional. Current campaign call asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_call_asset_count = 11 [(.google.api.field_behavior) = OPTIONAL];
* @return The campaignCallAssetCount.
*/
@java.lang.Override
public int getCampaignCallAssetCount() {
return campaignCallAssetCount_;
}
public static final int COUNTRY_CODES_FIELD_NUMBER = 13;
@SuppressWarnings("serial")
private com.google.protobuf.LazyStringArrayList countryCodes_ =
com.google.protobuf.LazyStringArrayList.emptyList();
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the countryCodes.
*/
public com.google.protobuf.ProtocolStringList
getCountryCodesList() {
return countryCodes_;
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of countryCodes.
*/
public int getCountryCodesCount() {
return countryCodes_.size();
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The countryCodes at the given index.
*/
public java.lang.String getCountryCodes(int index) {
return countryCodes_.get(index);
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the countryCodes at the given index.
*/
public com.google.protobuf.ByteString
getCountryCodesBytes(int index) {
return countryCodes_.getByteString(index);
}
public static final int LANGUAGE_CODES_FIELD_NUMBER = 14;
@SuppressWarnings("serial")
private com.google.protobuf.LazyStringArrayList languageCodes_ =
com.google.protobuf.LazyStringArrayList.emptyList();
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the languageCodes.
*/
public com.google.protobuf.ProtocolStringList
getLanguageCodesList() {
return languageCodes_;
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of languageCodes.
*/
public int getLanguageCodesCount() {
return languageCodes_.size();
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The languageCodes at the given index.
*/
public java.lang.String getLanguageCodes(int index) {
return languageCodes_.get(index);
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the languageCodes at the given index.
*/
public com.google.protobuf.ByteString
getLanguageCodesBytes(int index) {
return languageCodes_.getByteString(index);
}
public static final int POSITIVE_LOCATIONS_IDS_FIELD_NUMBER = 15;
@SuppressWarnings("serial")
private com.google.protobuf.Internal.LongList positiveLocationsIds_ =
emptyLongList();
/**
*
* Optional. Current campaign positive location ids.
* One of this field OR negative_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 positive_locations_ids = 15 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the positiveLocationsIds.
*/
@java.lang.Override
public java.util.List
getPositiveLocationsIdsList() {
return positiveLocationsIds_;
}
/**
*
* Optional. Current campaign positive location ids.
* One of this field OR negative_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 positive_locations_ids = 15 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of positiveLocationsIds.
*/
public int getPositiveLocationsIdsCount() {
return positiveLocationsIds_.size();
}
/**
*
* Optional. Current campaign positive location ids.
* One of this field OR negative_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 positive_locations_ids = 15 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The positiveLocationsIds at the given index.
*/
public long getPositiveLocationsIds(int index) {
return positiveLocationsIds_.getLong(index);
}
private int positiveLocationsIdsMemoizedSerializedSize = -1;
public static final int NEGATIVE_LOCATIONS_IDS_FIELD_NUMBER = 16;
@SuppressWarnings("serial")
private com.google.protobuf.Internal.LongList negativeLocationsIds_ =
emptyLongList();
/**
*
* Optional. Current campaign negative location ids.
* One of this field OR positive_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 negative_locations_ids = 16 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the negativeLocationsIds.
*/
@java.lang.Override
public java.util.List
getNegativeLocationsIdsList() {
return negativeLocationsIds_;
}
/**
*
* Optional. Current campaign negative location ids.
* One of this field OR positive_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 negative_locations_ids = 16 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of negativeLocationsIds.
*/
public int getNegativeLocationsIdsCount() {
return negativeLocationsIds_.size();
}
/**
*
* Optional. Current campaign negative location ids.
* One of this field OR positive_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 negative_locations_ids = 16 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The negativeLocationsIds at the given index.
*/
public long getNegativeLocationsIds(int index) {
return negativeLocationsIds_.getLong(index);
}
private int negativeLocationsIdsMemoizedSerializedSize = -1;
public static final int ASSET_GROUP_INFO_FIELD_NUMBER = 17;
@SuppressWarnings("serial")
private java.util.List assetGroupInfo_;
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public java.util.List getAssetGroupInfoList() {
return assetGroupInfo_;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public java.util.List extends com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfoOrBuilder>
getAssetGroupInfoOrBuilderList() {
return assetGroupInfo_;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public int getAssetGroupInfoCount() {
return assetGroupInfo_.size();
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo getAssetGroupInfo(int index) {
return assetGroupInfo_.get(index);
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfoOrBuilder getAssetGroupInfoOrBuilder(
int index) {
return assetGroupInfo_.get(index);
}
public static final int TARGET_PARTNER_SEARCH_NETWORK_FIELD_NUMBER = 18;
private boolean targetPartnerSearchNetwork_ = false;
/**
*
* Optional. If true, the campaign is opted into serving ads on the Google
* Partner Network. This field is optional for the following
* recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_partner_search_network = 18 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the targetPartnerSearchNetwork field is set.
*/
@java.lang.Override
public boolean hasTargetPartnerSearchNetwork() {
return ((bitField0_ & 0x00000080) != 0);
}
/**
*
* Optional. If true, the campaign is opted into serving ads on the Google
* Partner Network. This field is optional for the following
* recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_partner_search_network = 18 [(.google.api.field_behavior) = OPTIONAL];
* @return The targetPartnerSearchNetwork.
*/
@java.lang.Override
public boolean getTargetPartnerSearchNetwork() {
return targetPartnerSearchNetwork_;
}
public static final int TARGET_CONTENT_NETWORK_FIELD_NUMBER = 19;
private boolean targetContentNetwork_ = false;
/**
*
* Optional. If true, the campaign is opted into serving ads on specified
* placements in the Google Display Network. This field is optional for the
* following recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_content_network = 19 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the targetContentNetwork field is set.
*/
@java.lang.Override
public boolean hasTargetContentNetwork() {
return ((bitField0_ & 0x00000100) != 0);
}
/**
*
* Optional. If true, the campaign is opted into serving ads on specified
* placements in the Google Display Network. This field is optional for the
* following recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_content_network = 19 [(.google.api.field_behavior) = OPTIONAL];
* @return The targetContentNetwork.
*/
@java.lang.Override
public boolean getTargetContentNetwork() {
return targetContentNetwork_;
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
getSerializedSize();
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(customerId_)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, customerId_);
}
if (getRecommendationTypesList().size() > 0) {
output.writeUInt32NoTag(18);
output.writeUInt32NoTag(recommendationTypesMemoizedSerializedSize);
}
for (int i = 0; i < recommendationTypes_.size(); i++) {
output.writeEnumNoTag(recommendationTypes_.get(i));
}
if (advertisingChannelType_ != com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType.UNSPECIFIED.getNumber()) {
output.writeEnum(3, advertisingChannelType_);
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeInt32(4, campaignSitelinkCount_);
}
if (((bitField0_ & 0x00000002) != 0)) {
output.writeEnum(5, conversionTrackingStatus_);
}
if (((bitField0_ & 0x00000004) != 0)) {
output.writeMessage(6, getBiddingInfo());
}
for (int i = 0; i < adGroupInfo_.size(); i++) {
output.writeMessage(7, adGroupInfo_.get(i));
}
if (((bitField0_ & 0x00000008) != 0)) {
output.writeMessage(8, getSeedInfo());
}
if (((bitField0_ & 0x00000010) != 0)) {
output.writeMessage(9, getBudgetInfo());
}
if (((bitField0_ & 0x00000020) != 0)) {
output.writeInt32(10, campaignImageAssetCount_);
}
if (((bitField0_ & 0x00000040) != 0)) {
output.writeInt32(11, campaignCallAssetCount_);
}
for (int i = 0; i < countryCodes_.size(); i++) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 13, countryCodes_.getRaw(i));
}
for (int i = 0; i < languageCodes_.size(); i++) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 14, languageCodes_.getRaw(i));
}
if (getPositiveLocationsIdsList().size() > 0) {
output.writeUInt32NoTag(122);
output.writeUInt32NoTag(positiveLocationsIdsMemoizedSerializedSize);
}
for (int i = 0; i < positiveLocationsIds_.size(); i++) {
output.writeInt64NoTag(positiveLocationsIds_.getLong(i));
}
if (getNegativeLocationsIdsList().size() > 0) {
output.writeUInt32NoTag(130);
output.writeUInt32NoTag(negativeLocationsIdsMemoizedSerializedSize);
}
for (int i = 0; i < negativeLocationsIds_.size(); i++) {
output.writeInt64NoTag(negativeLocationsIds_.getLong(i));
}
for (int i = 0; i < assetGroupInfo_.size(); i++) {
output.writeMessage(17, assetGroupInfo_.get(i));
}
if (((bitField0_ & 0x00000080) != 0)) {
output.writeBool(18, targetPartnerSearchNetwork_);
}
if (((bitField0_ & 0x00000100) != 0)) {
output.writeBool(19, targetContentNetwork_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(customerId_)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, customerId_);
}
{
int dataSize = 0;
for (int i = 0; i < recommendationTypes_.size(); i++) {
dataSize += com.google.protobuf.CodedOutputStream
.computeEnumSizeNoTag(recommendationTypes_.get(i));
}
size += dataSize;
if (!getRecommendationTypesList().isEmpty()) { size += 1;
size += com.google.protobuf.CodedOutputStream
.computeUInt32SizeNoTag(dataSize);
}recommendationTypesMemoizedSerializedSize = dataSize;
}
if (advertisingChannelType_ != com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType.UNSPECIFIED.getNumber()) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(3, advertisingChannelType_);
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(4, campaignSitelinkCount_);
}
if (((bitField0_ & 0x00000002) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeEnumSize(5, conversionTrackingStatus_);
}
if (((bitField0_ & 0x00000004) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(6, getBiddingInfo());
}
for (int i = 0; i < adGroupInfo_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(7, adGroupInfo_.get(i));
}
if (((bitField0_ & 0x00000008) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(8, getSeedInfo());
}
if (((bitField0_ & 0x00000010) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(9, getBudgetInfo());
}
if (((bitField0_ & 0x00000020) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(10, campaignImageAssetCount_);
}
if (((bitField0_ & 0x00000040) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeInt32Size(11, campaignCallAssetCount_);
}
{
int dataSize = 0;
for (int i = 0; i < countryCodes_.size(); i++) {
dataSize += computeStringSizeNoTag(countryCodes_.getRaw(i));
}
size += dataSize;
size += 1 * getCountryCodesList().size();
}
{
int dataSize = 0;
for (int i = 0; i < languageCodes_.size(); i++) {
dataSize += computeStringSizeNoTag(languageCodes_.getRaw(i));
}
size += dataSize;
size += 1 * getLanguageCodesList().size();
}
{
int dataSize = 0;
for (int i = 0; i < positiveLocationsIds_.size(); i++) {
dataSize += com.google.protobuf.CodedOutputStream
.computeInt64SizeNoTag(positiveLocationsIds_.getLong(i));
}
size += dataSize;
if (!getPositiveLocationsIdsList().isEmpty()) {
size += 1;
size += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(dataSize);
}
positiveLocationsIdsMemoizedSerializedSize = dataSize;
}
{
int dataSize = 0;
for (int i = 0; i < negativeLocationsIds_.size(); i++) {
dataSize += com.google.protobuf.CodedOutputStream
.computeInt64SizeNoTag(negativeLocationsIds_.getLong(i));
}
size += dataSize;
if (!getNegativeLocationsIdsList().isEmpty()) {
size += 2;
size += com.google.protobuf.CodedOutputStream
.computeInt32SizeNoTag(dataSize);
}
negativeLocationsIdsMemoizedSerializedSize = dataSize;
}
for (int i = 0; i < assetGroupInfo_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(17, assetGroupInfo_.get(i));
}
if (((bitField0_ & 0x00000080) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeBoolSize(18, targetPartnerSearchNetwork_);
}
if (((bitField0_ & 0x00000100) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeBoolSize(19, targetContentNetwork_);
}
size += getUnknownFields().getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest)) {
return super.equals(obj);
}
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest other = (com.google.ads.googleads.v18.services.GenerateRecommendationsRequest) obj;
if (!getCustomerId()
.equals(other.getCustomerId())) return false;
if (!recommendationTypes_.equals(other.recommendationTypes_)) return false;
if (advertisingChannelType_ != other.advertisingChannelType_) return false;
if (hasCampaignSitelinkCount() != other.hasCampaignSitelinkCount()) return false;
if (hasCampaignSitelinkCount()) {
if (getCampaignSitelinkCount()
!= other.getCampaignSitelinkCount()) return false;
}
if (hasConversionTrackingStatus() != other.hasConversionTrackingStatus()) return false;
if (hasConversionTrackingStatus()) {
if (conversionTrackingStatus_ != other.conversionTrackingStatus_) return false;
}
if (hasBiddingInfo() != other.hasBiddingInfo()) return false;
if (hasBiddingInfo()) {
if (!getBiddingInfo()
.equals(other.getBiddingInfo())) return false;
}
if (!getAdGroupInfoList()
.equals(other.getAdGroupInfoList())) return false;
if (hasSeedInfo() != other.hasSeedInfo()) return false;
if (hasSeedInfo()) {
if (!getSeedInfo()
.equals(other.getSeedInfo())) return false;
}
if (hasBudgetInfo() != other.hasBudgetInfo()) return false;
if (hasBudgetInfo()) {
if (!getBudgetInfo()
.equals(other.getBudgetInfo())) return false;
}
if (hasCampaignImageAssetCount() != other.hasCampaignImageAssetCount()) return false;
if (hasCampaignImageAssetCount()) {
if (getCampaignImageAssetCount()
!= other.getCampaignImageAssetCount()) return false;
}
if (hasCampaignCallAssetCount() != other.hasCampaignCallAssetCount()) return false;
if (hasCampaignCallAssetCount()) {
if (getCampaignCallAssetCount()
!= other.getCampaignCallAssetCount()) return false;
}
if (!getCountryCodesList()
.equals(other.getCountryCodesList())) return false;
if (!getLanguageCodesList()
.equals(other.getLanguageCodesList())) return false;
if (!getPositiveLocationsIdsList()
.equals(other.getPositiveLocationsIdsList())) return false;
if (!getNegativeLocationsIdsList()
.equals(other.getNegativeLocationsIdsList())) return false;
if (!getAssetGroupInfoList()
.equals(other.getAssetGroupInfoList())) return false;
if (hasTargetPartnerSearchNetwork() != other.hasTargetPartnerSearchNetwork()) return false;
if (hasTargetPartnerSearchNetwork()) {
if (getTargetPartnerSearchNetwork()
!= other.getTargetPartnerSearchNetwork()) return false;
}
if (hasTargetContentNetwork() != other.hasTargetContentNetwork()) return false;
if (hasTargetContentNetwork()) {
if (getTargetContentNetwork()
!= other.getTargetContentNetwork()) return false;
}
if (!getUnknownFields().equals(other.getUnknownFields())) return false;
return true;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
hash = (37 * hash) + CUSTOMER_ID_FIELD_NUMBER;
hash = (53 * hash) + getCustomerId().hashCode();
if (getRecommendationTypesCount() > 0) {
hash = (37 * hash) + RECOMMENDATION_TYPES_FIELD_NUMBER;
hash = (53 * hash) + recommendationTypes_.hashCode();
}
hash = (37 * hash) + ADVERTISING_CHANNEL_TYPE_FIELD_NUMBER;
hash = (53 * hash) + advertisingChannelType_;
if (hasCampaignSitelinkCount()) {
hash = (37 * hash) + CAMPAIGN_SITELINK_COUNT_FIELD_NUMBER;
hash = (53 * hash) + getCampaignSitelinkCount();
}
if (hasConversionTrackingStatus()) {
hash = (37 * hash) + CONVERSION_TRACKING_STATUS_FIELD_NUMBER;
hash = (53 * hash) + conversionTrackingStatus_;
}
if (hasBiddingInfo()) {
hash = (37 * hash) + BIDDING_INFO_FIELD_NUMBER;
hash = (53 * hash) + getBiddingInfo().hashCode();
}
if (getAdGroupInfoCount() > 0) {
hash = (37 * hash) + AD_GROUP_INFO_FIELD_NUMBER;
hash = (53 * hash) + getAdGroupInfoList().hashCode();
}
if (hasSeedInfo()) {
hash = (37 * hash) + SEED_INFO_FIELD_NUMBER;
hash = (53 * hash) + getSeedInfo().hashCode();
}
if (hasBudgetInfo()) {
hash = (37 * hash) + BUDGET_INFO_FIELD_NUMBER;
hash = (53 * hash) + getBudgetInfo().hashCode();
}
if (hasCampaignImageAssetCount()) {
hash = (37 * hash) + CAMPAIGN_IMAGE_ASSET_COUNT_FIELD_NUMBER;
hash = (53 * hash) + getCampaignImageAssetCount();
}
if (hasCampaignCallAssetCount()) {
hash = (37 * hash) + CAMPAIGN_CALL_ASSET_COUNT_FIELD_NUMBER;
hash = (53 * hash) + getCampaignCallAssetCount();
}
if (getCountryCodesCount() > 0) {
hash = (37 * hash) + COUNTRY_CODES_FIELD_NUMBER;
hash = (53 * hash) + getCountryCodesList().hashCode();
}
if (getLanguageCodesCount() > 0) {
hash = (37 * hash) + LANGUAGE_CODES_FIELD_NUMBER;
hash = (53 * hash) + getLanguageCodesList().hashCode();
}
if (getPositiveLocationsIdsCount() > 0) {
hash = (37 * hash) + POSITIVE_LOCATIONS_IDS_FIELD_NUMBER;
hash = (53 * hash) + getPositiveLocationsIdsList().hashCode();
}
if (getNegativeLocationsIdsCount() > 0) {
hash = (37 * hash) + NEGATIVE_LOCATIONS_IDS_FIELD_NUMBER;
hash = (53 * hash) + getNegativeLocationsIdsList().hashCode();
}
if (getAssetGroupInfoCount() > 0) {
hash = (37 * hash) + ASSET_GROUP_INFO_FIELD_NUMBER;
hash = (53 * hash) + getAssetGroupInfoList().hashCode();
}
if (hasTargetPartnerSearchNetwork()) {
hash = (37 * hash) + TARGET_PARTNER_SEARCH_NETWORK_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
getTargetPartnerSearchNetwork());
}
if (hasTargetContentNetwork()) {
hash = (37 * hash) + TARGET_CONTENT_NETWORK_FIELD_NUMBER;
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
getTargetContentNetwork());
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Request message for
* [RecommendationService.GenerateRecommendations][google.ads.googleads.v18.services.RecommendationService.GenerateRecommendations].
*
*
* Protobuf type {@code google.ads.googleads.v18.services.GenerateRecommendationsRequest}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:google.ads.googleads.v18.services.GenerateRecommendationsRequest)
com.google.ads.googleads.v18.services.GenerateRecommendationsRequestOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.class, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.Builder.class);
}
// Construct using com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getBiddingInfoFieldBuilder();
getAdGroupInfoFieldBuilder();
getSeedInfoFieldBuilder();
getBudgetInfoFieldBuilder();
getAssetGroupInfoFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
customerId_ = "";
recommendationTypes_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
advertisingChannelType_ = 0;
campaignSitelinkCount_ = 0;
conversionTrackingStatus_ = 0;
biddingInfo_ = null;
if (biddingInfoBuilder_ != null) {
biddingInfoBuilder_.dispose();
biddingInfoBuilder_ = null;
}
if (adGroupInfoBuilder_ == null) {
adGroupInfo_ = java.util.Collections.emptyList();
} else {
adGroupInfo_ = null;
adGroupInfoBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000040);
seedInfo_ = null;
if (seedInfoBuilder_ != null) {
seedInfoBuilder_.dispose();
seedInfoBuilder_ = null;
}
budgetInfo_ = null;
if (budgetInfoBuilder_ != null) {
budgetInfoBuilder_.dispose();
budgetInfoBuilder_ = null;
}
campaignImageAssetCount_ = 0;
campaignCallAssetCount_ = 0;
countryCodes_ =
com.google.protobuf.LazyStringArrayList.emptyList();
languageCodes_ =
com.google.protobuf.LazyStringArrayList.emptyList();
positiveLocationsIds_ = emptyLongList();
negativeLocationsIds_ = emptyLongList();
if (assetGroupInfoBuilder_ == null) {
assetGroupInfo_ = java.util.Collections.emptyList();
} else {
assetGroupInfo_ = null;
assetGroupInfoBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00008000);
targetPartnerSearchNetwork_ = false;
targetContentNetwork_ = false;
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.ads.googleads.v18.services.RecommendationServiceProto.internal_static_google_ads_googleads_v18_services_GenerateRecommendationsRequest_descriptor;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest getDefaultInstanceForType() {
return com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.getDefaultInstance();
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest build() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest buildPartial() {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest result = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest result) {
if (((bitField0_ & 0x00000002) != 0)) {
recommendationTypes_ = java.util.Collections.unmodifiableList(recommendationTypes_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.recommendationTypes_ = recommendationTypes_;
if (adGroupInfoBuilder_ == null) {
if (((bitField0_ & 0x00000040) != 0)) {
adGroupInfo_ = java.util.Collections.unmodifiableList(adGroupInfo_);
bitField0_ = (bitField0_ & ~0x00000040);
}
result.adGroupInfo_ = adGroupInfo_;
} else {
result.adGroupInfo_ = adGroupInfoBuilder_.build();
}
if (assetGroupInfoBuilder_ == null) {
if (((bitField0_ & 0x00008000) != 0)) {
assetGroupInfo_ = java.util.Collections.unmodifiableList(assetGroupInfo_);
bitField0_ = (bitField0_ & ~0x00008000);
}
result.assetGroupInfo_ = assetGroupInfo_;
} else {
result.assetGroupInfo_ = assetGroupInfoBuilder_.build();
}
}
private void buildPartial0(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest result) {
int from_bitField0_ = bitField0_;
if (((from_bitField0_ & 0x00000001) != 0)) {
result.customerId_ = customerId_;
}
if (((from_bitField0_ & 0x00000004) != 0)) {
result.advertisingChannelType_ = advertisingChannelType_;
}
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000008) != 0)) {
result.campaignSitelinkCount_ = campaignSitelinkCount_;
to_bitField0_ |= 0x00000001;
}
if (((from_bitField0_ & 0x00000010) != 0)) {
result.conversionTrackingStatus_ = conversionTrackingStatus_;
to_bitField0_ |= 0x00000002;
}
if (((from_bitField0_ & 0x00000020) != 0)) {
result.biddingInfo_ = biddingInfoBuilder_ == null
? biddingInfo_
: biddingInfoBuilder_.build();
to_bitField0_ |= 0x00000004;
}
if (((from_bitField0_ & 0x00000080) != 0)) {
result.seedInfo_ = seedInfoBuilder_ == null
? seedInfo_
: seedInfoBuilder_.build();
to_bitField0_ |= 0x00000008;
}
if (((from_bitField0_ & 0x00000100) != 0)) {
result.budgetInfo_ = budgetInfoBuilder_ == null
? budgetInfo_
: budgetInfoBuilder_.build();
to_bitField0_ |= 0x00000010;
}
if (((from_bitField0_ & 0x00000200) != 0)) {
result.campaignImageAssetCount_ = campaignImageAssetCount_;
to_bitField0_ |= 0x00000020;
}
if (((from_bitField0_ & 0x00000400) != 0)) {
result.campaignCallAssetCount_ = campaignCallAssetCount_;
to_bitField0_ |= 0x00000040;
}
if (((from_bitField0_ & 0x00000800) != 0)) {
countryCodes_.makeImmutable();
result.countryCodes_ = countryCodes_;
}
if (((from_bitField0_ & 0x00001000) != 0)) {
languageCodes_.makeImmutable();
result.languageCodes_ = languageCodes_;
}
if (((from_bitField0_ & 0x00002000) != 0)) {
positiveLocationsIds_.makeImmutable();
result.positiveLocationsIds_ = positiveLocationsIds_;
}
if (((from_bitField0_ & 0x00004000) != 0)) {
negativeLocationsIds_.makeImmutable();
result.negativeLocationsIds_ = negativeLocationsIds_;
}
if (((from_bitField0_ & 0x00010000) != 0)) {
result.targetPartnerSearchNetwork_ = targetPartnerSearchNetwork_;
to_bitField0_ |= 0x00000080;
}
if (((from_bitField0_ & 0x00020000) != 0)) {
result.targetContentNetwork_ = targetContentNetwork_;
to_bitField0_ |= 0x00000100;
}
result.bitField0_ |= to_bitField0_;
}
@java.lang.Override
public Builder clone() {
return super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof com.google.ads.googleads.v18.services.GenerateRecommendationsRequest) {
return mergeFrom((com.google.ads.googleads.v18.services.GenerateRecommendationsRequest)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest other) {
if (other == com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.getDefaultInstance()) return this;
if (!other.getCustomerId().isEmpty()) {
customerId_ = other.customerId_;
bitField0_ |= 0x00000001;
onChanged();
}
if (!other.recommendationTypes_.isEmpty()) {
if (recommendationTypes_.isEmpty()) {
recommendationTypes_ = other.recommendationTypes_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureRecommendationTypesIsMutable();
recommendationTypes_.addAll(other.recommendationTypes_);
}
onChanged();
}
if (other.advertisingChannelType_ != 0) {
setAdvertisingChannelTypeValue(other.getAdvertisingChannelTypeValue());
}
if (other.hasCampaignSitelinkCount()) {
setCampaignSitelinkCount(other.getCampaignSitelinkCount());
}
if (other.hasConversionTrackingStatus()) {
setConversionTrackingStatus(other.getConversionTrackingStatus());
}
if (other.hasBiddingInfo()) {
mergeBiddingInfo(other.getBiddingInfo());
}
if (adGroupInfoBuilder_ == null) {
if (!other.adGroupInfo_.isEmpty()) {
if (adGroupInfo_.isEmpty()) {
adGroupInfo_ = other.adGroupInfo_;
bitField0_ = (bitField0_ & ~0x00000040);
} else {
ensureAdGroupInfoIsMutable();
adGroupInfo_.addAll(other.adGroupInfo_);
}
onChanged();
}
} else {
if (!other.adGroupInfo_.isEmpty()) {
if (adGroupInfoBuilder_.isEmpty()) {
adGroupInfoBuilder_.dispose();
adGroupInfoBuilder_ = null;
adGroupInfo_ = other.adGroupInfo_;
bitField0_ = (bitField0_ & ~0x00000040);
adGroupInfoBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getAdGroupInfoFieldBuilder() : null;
} else {
adGroupInfoBuilder_.addAllMessages(other.adGroupInfo_);
}
}
}
if (other.hasSeedInfo()) {
mergeSeedInfo(other.getSeedInfo());
}
if (other.hasBudgetInfo()) {
mergeBudgetInfo(other.getBudgetInfo());
}
if (other.hasCampaignImageAssetCount()) {
setCampaignImageAssetCount(other.getCampaignImageAssetCount());
}
if (other.hasCampaignCallAssetCount()) {
setCampaignCallAssetCount(other.getCampaignCallAssetCount());
}
if (!other.countryCodes_.isEmpty()) {
if (countryCodes_.isEmpty()) {
countryCodes_ = other.countryCodes_;
bitField0_ |= 0x00000800;
} else {
ensureCountryCodesIsMutable();
countryCodes_.addAll(other.countryCodes_);
}
onChanged();
}
if (!other.languageCodes_.isEmpty()) {
if (languageCodes_.isEmpty()) {
languageCodes_ = other.languageCodes_;
bitField0_ |= 0x00001000;
} else {
ensureLanguageCodesIsMutable();
languageCodes_.addAll(other.languageCodes_);
}
onChanged();
}
if (!other.positiveLocationsIds_.isEmpty()) {
if (positiveLocationsIds_.isEmpty()) {
positiveLocationsIds_ = other.positiveLocationsIds_;
positiveLocationsIds_.makeImmutable();
bitField0_ |= 0x00002000;
} else {
ensurePositiveLocationsIdsIsMutable();
positiveLocationsIds_.addAll(other.positiveLocationsIds_);
}
onChanged();
}
if (!other.negativeLocationsIds_.isEmpty()) {
if (negativeLocationsIds_.isEmpty()) {
negativeLocationsIds_ = other.negativeLocationsIds_;
negativeLocationsIds_.makeImmutable();
bitField0_ |= 0x00004000;
} else {
ensureNegativeLocationsIdsIsMutable();
negativeLocationsIds_.addAll(other.negativeLocationsIds_);
}
onChanged();
}
if (assetGroupInfoBuilder_ == null) {
if (!other.assetGroupInfo_.isEmpty()) {
if (assetGroupInfo_.isEmpty()) {
assetGroupInfo_ = other.assetGroupInfo_;
bitField0_ = (bitField0_ & ~0x00008000);
} else {
ensureAssetGroupInfoIsMutable();
assetGroupInfo_.addAll(other.assetGroupInfo_);
}
onChanged();
}
} else {
if (!other.assetGroupInfo_.isEmpty()) {
if (assetGroupInfoBuilder_.isEmpty()) {
assetGroupInfoBuilder_.dispose();
assetGroupInfoBuilder_ = null;
assetGroupInfo_ = other.assetGroupInfo_;
bitField0_ = (bitField0_ & ~0x00008000);
assetGroupInfoBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getAssetGroupInfoFieldBuilder() : null;
} else {
assetGroupInfoBuilder_.addAllMessages(other.assetGroupInfo_);
}
}
}
if (other.hasTargetPartnerSearchNetwork()) {
setTargetPartnerSearchNetwork(other.getTargetPartnerSearchNetwork());
}
if (other.hasTargetContentNetwork()) {
setTargetContentNetwork(other.getTargetContentNetwork());
}
this.mergeUnknownFields(other.getUnknownFields());
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
try {
boolean done = false;
while (!done) {
int tag = input.readTag();
switch (tag) {
case 0:
done = true;
break;
case 10: {
customerId_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 16: {
int tmpRaw = input.readEnum();
ensureRecommendationTypesIsMutable();
recommendationTypes_.add(tmpRaw);
break;
} // case 16
case 18: {
int length = input.readRawVarint32();
int oldLimit = input.pushLimit(length);
while(input.getBytesUntilLimit() > 0) {
int tmpRaw = input.readEnum();
ensureRecommendationTypesIsMutable();
recommendationTypes_.add(tmpRaw);
}
input.popLimit(oldLimit);
break;
} // case 18
case 24: {
advertisingChannelType_ = input.readEnum();
bitField0_ |= 0x00000004;
break;
} // case 24
case 32: {
campaignSitelinkCount_ = input.readInt32();
bitField0_ |= 0x00000008;
break;
} // case 32
case 40: {
conversionTrackingStatus_ = input.readEnum();
bitField0_ |= 0x00000010;
break;
} // case 40
case 50: {
input.readMessage(
getBiddingInfoFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000020;
break;
} // case 50
case 58: {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo m =
input.readMessage(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.parser(),
extensionRegistry);
if (adGroupInfoBuilder_ == null) {
ensureAdGroupInfoIsMutable();
adGroupInfo_.add(m);
} else {
adGroupInfoBuilder_.addMessage(m);
}
break;
} // case 58
case 66: {
input.readMessage(
getSeedInfoFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000080;
break;
} // case 66
case 74: {
input.readMessage(
getBudgetInfoFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000100;
break;
} // case 74
case 80: {
campaignImageAssetCount_ = input.readInt32();
bitField0_ |= 0x00000200;
break;
} // case 80
case 88: {
campaignCallAssetCount_ = input.readInt32();
bitField0_ |= 0x00000400;
break;
} // case 88
case 106: {
java.lang.String s = input.readStringRequireUtf8();
ensureCountryCodesIsMutable();
countryCodes_.add(s);
break;
} // case 106
case 114: {
java.lang.String s = input.readStringRequireUtf8();
ensureLanguageCodesIsMutable();
languageCodes_.add(s);
break;
} // case 114
case 120: {
long v = input.readInt64();
ensurePositiveLocationsIdsIsMutable();
positiveLocationsIds_.addLong(v);
break;
} // case 120
case 122: {
int length = input.readRawVarint32();
int limit = input.pushLimit(length);
ensurePositiveLocationsIdsIsMutable();
while (input.getBytesUntilLimit() > 0) {
positiveLocationsIds_.addLong(input.readInt64());
}
input.popLimit(limit);
break;
} // case 122
case 128: {
long v = input.readInt64();
ensureNegativeLocationsIdsIsMutable();
negativeLocationsIds_.addLong(v);
break;
} // case 128
case 130: {
int length = input.readRawVarint32();
int limit = input.pushLimit(length);
ensureNegativeLocationsIdsIsMutable();
while (input.getBytesUntilLimit() > 0) {
negativeLocationsIds_.addLong(input.readInt64());
}
input.popLimit(limit);
break;
} // case 130
case 138: {
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo m =
input.readMessage(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.parser(),
extensionRegistry);
if (assetGroupInfoBuilder_ == null) {
ensureAssetGroupInfoIsMutable();
assetGroupInfo_.add(m);
} else {
assetGroupInfoBuilder_.addMessage(m);
}
break;
} // case 138
case 144: {
targetPartnerSearchNetwork_ = input.readBool();
bitField0_ |= 0x00010000;
break;
} // case 144
case 152: {
targetContentNetwork_ = input.readBool();
bitField0_ |= 0x00020000;
break;
} // case 152
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object customerId_ = "";
/**
*
* Required. The ID of the customer generating recommendations.
*
*
* string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The customerId.
*/
public java.lang.String getCustomerId() {
java.lang.Object ref = customerId_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
customerId_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* Required. The ID of the customer generating recommendations.
*
*
* string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];
* @return The bytes for customerId.
*/
public com.google.protobuf.ByteString
getCustomerIdBytes() {
java.lang.Object ref = customerId_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
customerId_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* Required. The ID of the customer generating recommendations.
*
*
* string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];
* @param value The customerId to set.
* @return This builder for chaining.
*/
public Builder setCustomerId(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
customerId_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
/**
*
* Required. The ID of the customer generating recommendations.
*
*
* string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];
* @return This builder for chaining.
*/
public Builder clearCustomerId() {
customerId_ = getDefaultInstance().getCustomerId();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
return this;
}
/**
*
* Required. The ID of the customer generating recommendations.
*
*
* string customer_id = 1 [(.google.api.field_behavior) = REQUIRED];
* @param value The bytes for customerId to set.
* @return This builder for chaining.
*/
public Builder setCustomerIdBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
customerId_ = value;
bitField0_ |= 0x00000001;
onChanged();
return this;
}
private java.util.List recommendationTypes_ =
java.util.Collections.emptyList();
private void ensureRecommendationTypesIsMutable() {
if (!((bitField0_ & 0x00000002) != 0)) {
recommendationTypes_ = new java.util.ArrayList(recommendationTypes_);
bitField0_ |= 0x00000002;
}
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @return A list containing the recommendationTypes.
*/
public java.util.List getRecommendationTypesList() {
return new com.google.protobuf.Internal.ListAdapter<
java.lang.Integer, com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType>(recommendationTypes_, recommendationTypes_converter_);
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @return The count of recommendationTypes.
*/
public int getRecommendationTypesCount() {
return recommendationTypes_.size();
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @param index The index of the element to return.
* @return The recommendationTypes at the given index.
*/
public com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType getRecommendationTypes(int index) {
return recommendationTypes_converter_.convert(recommendationTypes_.get(index));
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @param index The index to set the value at.
* @param value The recommendationTypes to set.
* @return This builder for chaining.
*/
public Builder setRecommendationTypes(
int index, com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType value) {
if (value == null) {
throw new NullPointerException();
}
ensureRecommendationTypesIsMutable();
recommendationTypes_.set(index, value.getNumber());
onChanged();
return this;
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @param value The recommendationTypes to add.
* @return This builder for chaining.
*/
public Builder addRecommendationTypes(com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType value) {
if (value == null) {
throw new NullPointerException();
}
ensureRecommendationTypesIsMutable();
recommendationTypes_.add(value.getNumber());
onChanged();
return this;
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @param values The recommendationTypes to add.
* @return This builder for chaining.
*/
public Builder addAllRecommendationTypes(
java.lang.Iterable extends com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType> values) {
ensureRecommendationTypesIsMutable();
for (com.google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType value : values) {
recommendationTypes_.add(value.getNumber());
}
onChanged();
return this;
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @return This builder for chaining.
*/
public Builder clearRecommendationTypes() {
recommendationTypes_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
return this;
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @return A list containing the enum numeric values on the wire for recommendationTypes.
*/
public java.util.List
getRecommendationTypesValueList() {
return java.util.Collections.unmodifiableList(recommendationTypes_);
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @param index The index of the value to return.
* @return The enum numeric value on the wire of recommendationTypes at the given index.
*/
public int getRecommendationTypesValue(int index) {
return recommendationTypes_.get(index);
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @param index The index to set the value at.
* @param value The enum numeric value on the wire for recommendationTypes to set.
* @return This builder for chaining.
*/
public Builder setRecommendationTypesValue(
int index, int value) {
ensureRecommendationTypesIsMutable();
recommendationTypes_.set(index, value);
onChanged();
return this;
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @param value The enum numeric value on the wire for recommendationTypes to add.
* @return This builder for chaining.
*/
public Builder addRecommendationTypesValue(int value) {
ensureRecommendationTypesIsMutable();
recommendationTypes_.add(value);
onChanged();
return this;
}
/**
*
* Required. List of eligible recommendation_types to generate. If the
* uploaded criteria isn't sufficient to make a recommendation, or the
* campaign is already in the recommended state, no recommendation will be
* returned for that type. Generally, a recommendation is returned if all
* required fields for that recommendation_type are uploaded, but there are
* cases where this is still not sufficient.
*
* The following recommendation_types are supported for recommendation
* generation:
* CAMPAIGN_BUDGET, KEYWORD, MAXIMIZE_CLICKS_OPT_IN,
* MAXIMIZE_CONVERSIONS_OPT_IN, MAXIMIZE_CONVERSION_VALUE_OPT_IN,
* SET_TARGET_CPA, SET_TARGET_ROAS, SITELINK_ASSET, TARGET_CPA_OPT_IN,
* TARGET_ROAS_OPT_IN
*
*
* repeated .google.ads.googleads.v18.enums.RecommendationTypeEnum.RecommendationType recommendation_types = 2 [(.google.api.field_behavior) = REQUIRED];
* @param values The enum numeric values on the wire for recommendationTypes to add.
* @return This builder for chaining.
*/
public Builder addAllRecommendationTypesValue(
java.lang.Iterable values) {
ensureRecommendationTypesIsMutable();
for (int value : values) {
recommendationTypes_.add(value);
}
onChanged();
return this;
}
private int advertisingChannelType_ = 0;
/**
*
* Required. Advertising channel type of the campaign.
* The following advertising_channel_types are supported for recommendation
* generation:
* PERFORMANCE_MAX and SEARCH
*
*
* .google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType advertising_channel_type = 3 [(.google.api.field_behavior) = REQUIRED];
* @return The enum numeric value on the wire for advertisingChannelType.
*/
@java.lang.Override public int getAdvertisingChannelTypeValue() {
return advertisingChannelType_;
}
/**
*
* Required. Advertising channel type of the campaign.
* The following advertising_channel_types are supported for recommendation
* generation:
* PERFORMANCE_MAX and SEARCH
*
*
* .google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType advertising_channel_type = 3 [(.google.api.field_behavior) = REQUIRED];
* @param value The enum numeric value on the wire for advertisingChannelType to set.
* @return This builder for chaining.
*/
public Builder setAdvertisingChannelTypeValue(int value) {
advertisingChannelType_ = value;
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Required. Advertising channel type of the campaign.
* The following advertising_channel_types are supported for recommendation
* generation:
* PERFORMANCE_MAX and SEARCH
*
*
* .google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType advertising_channel_type = 3 [(.google.api.field_behavior) = REQUIRED];
* @return The advertisingChannelType.
*/
@java.lang.Override
public com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType getAdvertisingChannelType() {
com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType result = com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType.forNumber(advertisingChannelType_);
return result == null ? com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType.UNRECOGNIZED : result;
}
/**
*
* Required. Advertising channel type of the campaign.
* The following advertising_channel_types are supported for recommendation
* generation:
* PERFORMANCE_MAX and SEARCH
*
*
* .google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType advertising_channel_type = 3 [(.google.api.field_behavior) = REQUIRED];
* @param value The advertisingChannelType to set.
* @return This builder for chaining.
*/
public Builder setAdvertisingChannelType(com.google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000004;
advertisingChannelType_ = value.getNumber();
onChanged();
return this;
}
/**
*
* Required. Advertising channel type of the campaign.
* The following advertising_channel_types are supported for recommendation
* generation:
* PERFORMANCE_MAX and SEARCH
*
*
* .google.ads.googleads.v18.enums.AdvertisingChannelTypeEnum.AdvertisingChannelType advertising_channel_type = 3 [(.google.api.field_behavior) = REQUIRED];
* @return This builder for chaining.
*/
public Builder clearAdvertisingChannelType() {
bitField0_ = (bitField0_ & ~0x00000004);
advertisingChannelType_ = 0;
onChanged();
return this;
}
private int campaignSitelinkCount_ ;
/**
*
* Optional. Number of sitelinks on the campaign.
* This field is necessary for the following recommendation_types:
* SITELINK_ASSET
*
*
* optional int32 campaign_sitelink_count = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the campaignSitelinkCount field is set.
*/
@java.lang.Override
public boolean hasCampaignSitelinkCount() {
return ((bitField0_ & 0x00000008) != 0);
}
/**
*
* Optional. Number of sitelinks on the campaign.
* This field is necessary for the following recommendation_types:
* SITELINK_ASSET
*
*
* optional int32 campaign_sitelink_count = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return The campaignSitelinkCount.
*/
@java.lang.Override
public int getCampaignSitelinkCount() {
return campaignSitelinkCount_;
}
/**
*
* Optional. Number of sitelinks on the campaign.
* This field is necessary for the following recommendation_types:
* SITELINK_ASSET
*
*
* optional int32 campaign_sitelink_count = 4 [(.google.api.field_behavior) = OPTIONAL];
* @param value The campaignSitelinkCount to set.
* @return This builder for chaining.
*/
public Builder setCampaignSitelinkCount(int value) {
campaignSitelinkCount_ = value;
bitField0_ |= 0x00000008;
onChanged();
return this;
}
/**
*
* Optional. Number of sitelinks on the campaign.
* This field is necessary for the following recommendation_types:
* SITELINK_ASSET
*
*
* optional int32 campaign_sitelink_count = 4 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearCampaignSitelinkCount() {
bitField0_ = (bitField0_ & ~0x00000008);
campaignSitelinkCount_ = 0;
onChanged();
return this;
}
private int conversionTrackingStatus_ = 0;
/**
*
* Optional. Current conversion tracking status.
* This field is necessary for the following recommendation_types:
* MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus conversion_tracking_status = 5 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the conversionTrackingStatus field is set.
*/
@java.lang.Override public boolean hasConversionTrackingStatus() {
return ((bitField0_ & 0x00000010) != 0);
}
/**
*
* Optional. Current conversion tracking status.
* This field is necessary for the following recommendation_types:
* MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus conversion_tracking_status = 5 [(.google.api.field_behavior) = OPTIONAL];
* @return The enum numeric value on the wire for conversionTrackingStatus.
*/
@java.lang.Override public int getConversionTrackingStatusValue() {
return conversionTrackingStatus_;
}
/**
*
* Optional. Current conversion tracking status.
* This field is necessary for the following recommendation_types:
* MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus conversion_tracking_status = 5 [(.google.api.field_behavior) = OPTIONAL];
* @param value The enum numeric value on the wire for conversionTrackingStatus to set.
* @return This builder for chaining.
*/
public Builder setConversionTrackingStatusValue(int value) {
conversionTrackingStatus_ = value;
bitField0_ |= 0x00000010;
onChanged();
return this;
}
/**
*
* Optional. Current conversion tracking status.
* This field is necessary for the following recommendation_types:
* MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus conversion_tracking_status = 5 [(.google.api.field_behavior) = OPTIONAL];
* @return The conversionTrackingStatus.
*/
@java.lang.Override
public com.google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus getConversionTrackingStatus() {
com.google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus result = com.google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus.forNumber(conversionTrackingStatus_);
return result == null ? com.google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus.UNRECOGNIZED : result;
}
/**
*
* Optional. Current conversion tracking status.
* This field is necessary for the following recommendation_types:
* MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus conversion_tracking_status = 5 [(.google.api.field_behavior) = OPTIONAL];
* @param value The conversionTrackingStatus to set.
* @return This builder for chaining.
*/
public Builder setConversionTrackingStatus(com.google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000010;
conversionTrackingStatus_ = value.getNumber();
onChanged();
return this;
}
/**
*
* Optional. Current conversion tracking status.
* This field is necessary for the following recommendation_types:
* MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.enums.ConversionTrackingStatusEnum.ConversionTrackingStatus conversion_tracking_status = 5 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearConversionTrackingStatus() {
bitField0_ = (bitField0_ & ~0x00000010);
conversionTrackingStatus_ = 0;
onChanged();
return this;
}
private com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo biddingInfo_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfoOrBuilder> biddingInfoBuilder_;
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the biddingInfo field is set.
*/
public boolean hasBiddingInfo() {
return ((bitField0_ & 0x00000020) != 0);
}
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
* @return The biddingInfo.
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo getBiddingInfo() {
if (biddingInfoBuilder_ == null) {
return biddingInfo_ == null ? com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.getDefaultInstance() : biddingInfo_;
} else {
return biddingInfoBuilder_.getMessage();
}
}
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setBiddingInfo(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo value) {
if (biddingInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
biddingInfo_ = value;
} else {
biddingInfoBuilder_.setMessage(value);
}
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setBiddingInfo(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.Builder builderForValue) {
if (biddingInfoBuilder_ == null) {
biddingInfo_ = builderForValue.build();
} else {
biddingInfoBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000020;
onChanged();
return this;
}
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder mergeBiddingInfo(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo value) {
if (biddingInfoBuilder_ == null) {
if (((bitField0_ & 0x00000020) != 0) &&
biddingInfo_ != null &&
biddingInfo_ != com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.getDefaultInstance()) {
getBiddingInfoBuilder().mergeFrom(value);
} else {
biddingInfo_ = value;
}
} else {
biddingInfoBuilder_.mergeFrom(value);
}
if (biddingInfo_ != null) {
bitField0_ |= 0x00000020;
onChanged();
}
return this;
}
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder clearBiddingInfo() {
bitField0_ = (bitField0_ & ~0x00000020);
biddingInfo_ = null;
if (biddingInfoBuilder_ != null) {
biddingInfoBuilder_.dispose();
biddingInfoBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.Builder getBiddingInfoBuilder() {
bitField0_ |= 0x00000020;
onChanged();
return getBiddingInfoFieldBuilder().getBuilder();
}
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfoOrBuilder getBiddingInfoOrBuilder() {
if (biddingInfoBuilder_ != null) {
return biddingInfoBuilder_.getMessageOrBuilder();
} else {
return biddingInfo_ == null ?
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.getDefaultInstance() : biddingInfo_;
}
}
/**
*
* Optional. Current bidding information of the campaign.
* This field is necessary for the following recommendation_types:
* CAMPAIGN_BUDGET, MAXIMIZE_CLICKS_OPT_IN, MAXIMIZE_CONVERSIONS_OPT_IN,
* MAXIMIZE_CONVERSION_VALUE_OPT_IN, SET_TARGET_CPA, SET_TARGET_ROAS,
* TARGET_CPA_OPT_IN, TARGET_ROAS_OPT_IN
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo bidding_info = 6 [(.google.api.field_behavior) = OPTIONAL];
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfoOrBuilder>
getBiddingInfoFieldBuilder() {
if (biddingInfoBuilder_ == null) {
biddingInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BiddingInfoOrBuilder>(
getBiddingInfo(),
getParentForChildren(),
isClean());
biddingInfo_ = null;
}
return biddingInfoBuilder_;
}
private java.util.List adGroupInfo_ =
java.util.Collections.emptyList();
private void ensureAdGroupInfoIsMutable() {
if (!((bitField0_ & 0x00000040) != 0)) {
adGroupInfo_ = new java.util.ArrayList(adGroupInfo_);
bitField0_ |= 0x00000040;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfoOrBuilder> adGroupInfoBuilder_;
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public java.util.List getAdGroupInfoList() {
if (adGroupInfoBuilder_ == null) {
return java.util.Collections.unmodifiableList(adGroupInfo_);
} else {
return adGroupInfoBuilder_.getMessageList();
}
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public int getAdGroupInfoCount() {
if (adGroupInfoBuilder_ == null) {
return adGroupInfo_.size();
} else {
return adGroupInfoBuilder_.getCount();
}
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo getAdGroupInfo(int index) {
if (adGroupInfoBuilder_ == null) {
return adGroupInfo_.get(index);
} else {
return adGroupInfoBuilder_.getMessage(index);
}
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setAdGroupInfo(
int index, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo value) {
if (adGroupInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAdGroupInfoIsMutable();
adGroupInfo_.set(index, value);
onChanged();
} else {
adGroupInfoBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setAdGroupInfo(
int index, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder builderForValue) {
if (adGroupInfoBuilder_ == null) {
ensureAdGroupInfoIsMutable();
adGroupInfo_.set(index, builderForValue.build());
onChanged();
} else {
adGroupInfoBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAdGroupInfo(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo value) {
if (adGroupInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAdGroupInfoIsMutable();
adGroupInfo_.add(value);
onChanged();
} else {
adGroupInfoBuilder_.addMessage(value);
}
return this;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAdGroupInfo(
int index, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo value) {
if (adGroupInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAdGroupInfoIsMutable();
adGroupInfo_.add(index, value);
onChanged();
} else {
adGroupInfoBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAdGroupInfo(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder builderForValue) {
if (adGroupInfoBuilder_ == null) {
ensureAdGroupInfoIsMutable();
adGroupInfo_.add(builderForValue.build());
onChanged();
} else {
adGroupInfoBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAdGroupInfo(
int index, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder builderForValue) {
if (adGroupInfoBuilder_ == null) {
ensureAdGroupInfoIsMutable();
adGroupInfo_.add(index, builderForValue.build());
onChanged();
} else {
adGroupInfoBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAllAdGroupInfo(
java.lang.Iterable extends com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo> values) {
if (adGroupInfoBuilder_ == null) {
ensureAdGroupInfoIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, adGroupInfo_);
onChanged();
} else {
adGroupInfoBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder clearAdGroupInfo() {
if (adGroupInfoBuilder_ == null) {
adGroupInfo_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000040);
onChanged();
} else {
adGroupInfoBuilder_.clear();
}
return this;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder removeAdGroupInfo(int index) {
if (adGroupInfoBuilder_ == null) {
ensureAdGroupInfoIsMutable();
adGroupInfo_.remove(index);
onChanged();
} else {
adGroupInfoBuilder_.remove(index);
}
return this;
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder getAdGroupInfoBuilder(
int index) {
return getAdGroupInfoFieldBuilder().getBuilder(index);
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfoOrBuilder getAdGroupInfoOrBuilder(
int index) {
if (adGroupInfoBuilder_ == null) {
return adGroupInfo_.get(index); } else {
return adGroupInfoBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public java.util.List extends com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfoOrBuilder>
getAdGroupInfoOrBuilderList() {
if (adGroupInfoBuilder_ != null) {
return adGroupInfoBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(adGroupInfo_);
}
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder addAdGroupInfoBuilder() {
return getAdGroupInfoFieldBuilder().addBuilder(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.getDefaultInstance());
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder addAdGroupInfoBuilder(
int index) {
return getAdGroupInfoFieldBuilder().addBuilder(
index, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.getDefaultInstance());
}
/**
*
* Optional. Current AdGroup Information.
* Supports information from a single AdGroup.
* This field is optional for the following recommendation_types:
* KEYWORD
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo ad_group_info = 7 [(.google.api.field_behavior) = OPTIONAL];
*/
public java.util.List
getAdGroupInfoBuilderList() {
return getAdGroupInfoFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfoOrBuilder>
getAdGroupInfoFieldBuilder() {
if (adGroupInfoBuilder_ == null) {
adGroupInfoBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AdGroupInfoOrBuilder>(
adGroupInfo_,
((bitField0_ & 0x00000040) != 0),
getParentForChildren(),
isClean());
adGroupInfo_ = null;
}
return adGroupInfoBuilder_;
}
private com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seedInfo_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfoOrBuilder> seedInfoBuilder_;
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the seedInfo field is set.
*/
public boolean hasSeedInfo() {
return ((bitField0_ & 0x00000080) != 0);
}
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
* @return The seedInfo.
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo getSeedInfo() {
if (seedInfoBuilder_ == null) {
return seedInfo_ == null ? com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.getDefaultInstance() : seedInfo_;
} else {
return seedInfoBuilder_.getMessage();
}
}
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setSeedInfo(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo value) {
if (seedInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
seedInfo_ = value;
} else {
seedInfoBuilder_.setMessage(value);
}
bitField0_ |= 0x00000080;
onChanged();
return this;
}
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setSeedInfo(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.Builder builderForValue) {
if (seedInfoBuilder_ == null) {
seedInfo_ = builderForValue.build();
} else {
seedInfoBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000080;
onChanged();
return this;
}
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder mergeSeedInfo(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo value) {
if (seedInfoBuilder_ == null) {
if (((bitField0_ & 0x00000080) != 0) &&
seedInfo_ != null &&
seedInfo_ != com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.getDefaultInstance()) {
getSeedInfoBuilder().mergeFrom(value);
} else {
seedInfo_ = value;
}
} else {
seedInfoBuilder_.mergeFrom(value);
}
if (seedInfo_ != null) {
bitField0_ |= 0x00000080;
onChanged();
}
return this;
}
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder clearSeedInfo() {
bitField0_ = (bitField0_ & ~0x00000080);
seedInfo_ = null;
if (seedInfoBuilder_ != null) {
seedInfoBuilder_.dispose();
seedInfoBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.Builder getSeedInfoBuilder() {
bitField0_ |= 0x00000080;
onChanged();
return getSeedInfoFieldBuilder().getBuilder();
}
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfoOrBuilder getSeedInfoOrBuilder() {
if (seedInfoBuilder_ != null) {
return seedInfoBuilder_.getMessageOrBuilder();
} else {
return seedInfo_ == null ?
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.getDefaultInstance() : seedInfo_;
}
}
/**
*
* Optional. Seed information for Keywords.
* This field is necessary for the following recommendation_types:
* KEYWORD
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo seed_info = 8 [(.google.api.field_behavior) = OPTIONAL];
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfoOrBuilder>
getSeedInfoFieldBuilder() {
if (seedInfoBuilder_ == null) {
seedInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.SeedInfoOrBuilder>(
getSeedInfo(),
getParentForChildren(),
isClean());
seedInfo_ = null;
}
return seedInfoBuilder_;
}
private com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budgetInfo_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfoOrBuilder> budgetInfoBuilder_;
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the budgetInfo field is set.
*/
public boolean hasBudgetInfo() {
return ((bitField0_ & 0x00000100) != 0);
}
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
* @return The budgetInfo.
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo getBudgetInfo() {
if (budgetInfoBuilder_ == null) {
return budgetInfo_ == null ? com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.getDefaultInstance() : budgetInfo_;
} else {
return budgetInfoBuilder_.getMessage();
}
}
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setBudgetInfo(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo value) {
if (budgetInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
budgetInfo_ = value;
} else {
budgetInfoBuilder_.setMessage(value);
}
bitField0_ |= 0x00000100;
onChanged();
return this;
}
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setBudgetInfo(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.Builder builderForValue) {
if (budgetInfoBuilder_ == null) {
budgetInfo_ = builderForValue.build();
} else {
budgetInfoBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000100;
onChanged();
return this;
}
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder mergeBudgetInfo(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo value) {
if (budgetInfoBuilder_ == null) {
if (((bitField0_ & 0x00000100) != 0) &&
budgetInfo_ != null &&
budgetInfo_ != com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.getDefaultInstance()) {
getBudgetInfoBuilder().mergeFrom(value);
} else {
budgetInfo_ = value;
}
} else {
budgetInfoBuilder_.mergeFrom(value);
}
if (budgetInfo_ != null) {
bitField0_ |= 0x00000100;
onChanged();
}
return this;
}
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder clearBudgetInfo() {
bitField0_ = (bitField0_ & ~0x00000100);
budgetInfo_ = null;
if (budgetInfoBuilder_ != null) {
budgetInfoBuilder_.dispose();
budgetInfoBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.Builder getBudgetInfoBuilder() {
bitField0_ |= 0x00000100;
onChanged();
return getBudgetInfoFieldBuilder().getBuilder();
}
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfoOrBuilder getBudgetInfoOrBuilder() {
if (budgetInfoBuilder_ != null) {
return budgetInfoBuilder_.getMessageOrBuilder();
} else {
return budgetInfo_ == null ?
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.getDefaultInstance() : budgetInfo_;
}
}
/**
*
* Optional. Current budget information.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional .google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo budget_info = 9 [(.google.api.field_behavior) = OPTIONAL];
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfoOrBuilder>
getBudgetInfoFieldBuilder() {
if (budgetInfoBuilder_ == null) {
budgetInfoBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.BudgetInfoOrBuilder>(
getBudgetInfo(),
getParentForChildren(),
isClean());
budgetInfo_ = null;
}
return budgetInfoBuilder_;
}
private int campaignImageAssetCount_ ;
/**
*
* Optional. Current campaign image asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_image_asset_count = 10 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the campaignImageAssetCount field is set.
*/
@java.lang.Override
public boolean hasCampaignImageAssetCount() {
return ((bitField0_ & 0x00000200) != 0);
}
/**
*
* Optional. Current campaign image asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_image_asset_count = 10 [(.google.api.field_behavior) = OPTIONAL];
* @return The campaignImageAssetCount.
*/
@java.lang.Override
public int getCampaignImageAssetCount() {
return campaignImageAssetCount_;
}
/**
*
* Optional. Current campaign image asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_image_asset_count = 10 [(.google.api.field_behavior) = OPTIONAL];
* @param value The campaignImageAssetCount to set.
* @return This builder for chaining.
*/
public Builder setCampaignImageAssetCount(int value) {
campaignImageAssetCount_ = value;
bitField0_ |= 0x00000200;
onChanged();
return this;
}
/**
*
* Optional. Current campaign image asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_image_asset_count = 10 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearCampaignImageAssetCount() {
bitField0_ = (bitField0_ & ~0x00000200);
campaignImageAssetCount_ = 0;
onChanged();
return this;
}
private int campaignCallAssetCount_ ;
/**
*
* Optional. Current campaign call asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_call_asset_count = 11 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the campaignCallAssetCount field is set.
*/
@java.lang.Override
public boolean hasCampaignCallAssetCount() {
return ((bitField0_ & 0x00000400) != 0);
}
/**
*
* Optional. Current campaign call asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_call_asset_count = 11 [(.google.api.field_behavior) = OPTIONAL];
* @return The campaignCallAssetCount.
*/
@java.lang.Override
public int getCampaignCallAssetCount() {
return campaignCallAssetCount_;
}
/**
*
* Optional. Current campaign call asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_call_asset_count = 11 [(.google.api.field_behavior) = OPTIONAL];
* @param value The campaignCallAssetCount to set.
* @return This builder for chaining.
*/
public Builder setCampaignCallAssetCount(int value) {
campaignCallAssetCount_ = value;
bitField0_ |= 0x00000400;
onChanged();
return this;
}
/**
*
* Optional. Current campaign call asset count.
* This field is optional for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* optional int32 campaign_call_asset_count = 11 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearCampaignCallAssetCount() {
bitField0_ = (bitField0_ & ~0x00000400);
campaignCallAssetCount_ = 0;
onChanged();
return this;
}
private com.google.protobuf.LazyStringArrayList countryCodes_ =
com.google.protobuf.LazyStringArrayList.emptyList();
private void ensureCountryCodesIsMutable() {
if (!countryCodes_.isModifiable()) {
countryCodes_ = new com.google.protobuf.LazyStringArrayList(countryCodes_);
}
bitField0_ |= 0x00000800;
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the countryCodes.
*/
public com.google.protobuf.ProtocolStringList
getCountryCodesList() {
countryCodes_.makeImmutable();
return countryCodes_;
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of countryCodes.
*/
public int getCountryCodesCount() {
return countryCodes_.size();
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The countryCodes at the given index.
*/
public java.lang.String getCountryCodes(int index) {
return countryCodes_.get(index);
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the countryCodes at the given index.
*/
public com.google.protobuf.ByteString
getCountryCodesBytes(int index) {
return countryCodes_.getByteString(index);
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index to set the value at.
* @param value The countryCodes to set.
* @return This builder for chaining.
*/
public Builder setCountryCodes(
int index, java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureCountryCodesIsMutable();
countryCodes_.set(index, value);
bitField0_ |= 0x00000800;
onChanged();
return this;
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @param value The countryCodes to add.
* @return This builder for chaining.
*/
public Builder addCountryCodes(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureCountryCodesIsMutable();
countryCodes_.add(value);
bitField0_ |= 0x00000800;
onChanged();
return this;
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @param values The countryCodes to add.
* @return This builder for chaining.
*/
public Builder addAllCountryCodes(
java.lang.Iterable values) {
ensureCountryCodesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, countryCodes_);
bitField0_ |= 0x00000800;
onChanged();
return this;
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearCountryCodes() {
countryCodes_ =
com.google.protobuf.LazyStringArrayList.emptyList();
bitField0_ = (bitField0_ & ~0x00000800);;
onChanged();
return this;
}
/**
*
* Optional. Current campaign country codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string country_codes = 13 [(.google.api.field_behavior) = OPTIONAL];
* @param value The bytes of the countryCodes to add.
* @return This builder for chaining.
*/
public Builder addCountryCodesBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
ensureCountryCodesIsMutable();
countryCodes_.add(value);
bitField0_ |= 0x00000800;
onChanged();
return this;
}
private com.google.protobuf.LazyStringArrayList languageCodes_ =
com.google.protobuf.LazyStringArrayList.emptyList();
private void ensureLanguageCodesIsMutable() {
if (!languageCodes_.isModifiable()) {
languageCodes_ = new com.google.protobuf.LazyStringArrayList(languageCodes_);
}
bitField0_ |= 0x00001000;
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the languageCodes.
*/
public com.google.protobuf.ProtocolStringList
getLanguageCodesList() {
languageCodes_.makeImmutable();
return languageCodes_;
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of languageCodes.
*/
public int getLanguageCodesCount() {
return languageCodes_.size();
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The languageCodes at the given index.
*/
public java.lang.String getLanguageCodes(int index) {
return languageCodes_.get(index);
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the value to return.
* @return The bytes of the languageCodes at the given index.
*/
public com.google.protobuf.ByteString
getLanguageCodesBytes(int index) {
return languageCodes_.getByteString(index);
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index to set the value at.
* @param value The languageCodes to set.
* @return This builder for chaining.
*/
public Builder setLanguageCodes(
int index, java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureLanguageCodesIsMutable();
languageCodes_.set(index, value);
bitField0_ |= 0x00001000;
onChanged();
return this;
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @param value The languageCodes to add.
* @return This builder for chaining.
*/
public Builder addLanguageCodes(
java.lang.String value) {
if (value == null) { throw new NullPointerException(); }
ensureLanguageCodesIsMutable();
languageCodes_.add(value);
bitField0_ |= 0x00001000;
onChanged();
return this;
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @param values The languageCodes to add.
* @return This builder for chaining.
*/
public Builder addAllLanguageCodes(
java.lang.Iterable values) {
ensureLanguageCodesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, languageCodes_);
bitField0_ |= 0x00001000;
onChanged();
return this;
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearLanguageCodes() {
languageCodes_ =
com.google.protobuf.LazyStringArrayList.emptyList();
bitField0_ = (bitField0_ & ~0x00001000);;
onChanged();
return this;
}
/**
*
* Optional. Current campaign language codes.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated string language_codes = 14 [(.google.api.field_behavior) = OPTIONAL];
* @param value The bytes of the languageCodes to add.
* @return This builder for chaining.
*/
public Builder addLanguageCodesBytes(
com.google.protobuf.ByteString value) {
if (value == null) { throw new NullPointerException(); }
checkByteStringIsUtf8(value);
ensureLanguageCodesIsMutable();
languageCodes_.add(value);
bitField0_ |= 0x00001000;
onChanged();
return this;
}
private com.google.protobuf.Internal.LongList positiveLocationsIds_ = emptyLongList();
private void ensurePositiveLocationsIdsIsMutable() {
if (!positiveLocationsIds_.isModifiable()) {
positiveLocationsIds_ = makeMutableCopy(positiveLocationsIds_);
}
bitField0_ |= 0x00002000;
}
/**
*
* Optional. Current campaign positive location ids.
* One of this field OR negative_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 positive_locations_ids = 15 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the positiveLocationsIds.
*/
public java.util.List
getPositiveLocationsIdsList() {
positiveLocationsIds_.makeImmutable();
return positiveLocationsIds_;
}
/**
*
* Optional. Current campaign positive location ids.
* One of this field OR negative_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 positive_locations_ids = 15 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of positiveLocationsIds.
*/
public int getPositiveLocationsIdsCount() {
return positiveLocationsIds_.size();
}
/**
*
* Optional. Current campaign positive location ids.
* One of this field OR negative_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 positive_locations_ids = 15 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The positiveLocationsIds at the given index.
*/
public long getPositiveLocationsIds(int index) {
return positiveLocationsIds_.getLong(index);
}
/**
*
* Optional. Current campaign positive location ids.
* One of this field OR negative_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 positive_locations_ids = 15 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index to set the value at.
* @param value The positiveLocationsIds to set.
* @return This builder for chaining.
*/
public Builder setPositiveLocationsIds(
int index, long value) {
ensurePositiveLocationsIdsIsMutable();
positiveLocationsIds_.setLong(index, value);
bitField0_ |= 0x00002000;
onChanged();
return this;
}
/**
*
* Optional. Current campaign positive location ids.
* One of this field OR negative_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 positive_locations_ids = 15 [(.google.api.field_behavior) = OPTIONAL];
* @param value The positiveLocationsIds to add.
* @return This builder for chaining.
*/
public Builder addPositiveLocationsIds(long value) {
ensurePositiveLocationsIdsIsMutable();
positiveLocationsIds_.addLong(value);
bitField0_ |= 0x00002000;
onChanged();
return this;
}
/**
*
* Optional. Current campaign positive location ids.
* One of this field OR negative_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 positive_locations_ids = 15 [(.google.api.field_behavior) = OPTIONAL];
* @param values The positiveLocationsIds to add.
* @return This builder for chaining.
*/
public Builder addAllPositiveLocationsIds(
java.lang.Iterable extends java.lang.Long> values) {
ensurePositiveLocationsIdsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, positiveLocationsIds_);
bitField0_ |= 0x00002000;
onChanged();
return this;
}
/**
*
* Optional. Current campaign positive location ids.
* One of this field OR negative_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 positive_locations_ids = 15 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearPositiveLocationsIds() {
positiveLocationsIds_ = emptyLongList();
bitField0_ = (bitField0_ & ~0x00002000);
onChanged();
return this;
}
private com.google.protobuf.Internal.LongList negativeLocationsIds_ = emptyLongList();
private void ensureNegativeLocationsIdsIsMutable() {
if (!negativeLocationsIds_.isModifiable()) {
negativeLocationsIds_ = makeMutableCopy(negativeLocationsIds_);
}
bitField0_ |= 0x00004000;
}
/**
*
* Optional. Current campaign negative location ids.
* One of this field OR positive_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 negative_locations_ids = 16 [(.google.api.field_behavior) = OPTIONAL];
* @return A list containing the negativeLocationsIds.
*/
public java.util.List
getNegativeLocationsIdsList() {
negativeLocationsIds_.makeImmutable();
return negativeLocationsIds_;
}
/**
*
* Optional. Current campaign negative location ids.
* One of this field OR positive_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 negative_locations_ids = 16 [(.google.api.field_behavior) = OPTIONAL];
* @return The count of negativeLocationsIds.
*/
public int getNegativeLocationsIdsCount() {
return negativeLocationsIds_.size();
}
/**
*
* Optional. Current campaign negative location ids.
* One of this field OR positive_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 negative_locations_ids = 16 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index of the element to return.
* @return The negativeLocationsIds at the given index.
*/
public long getNegativeLocationsIds(int index) {
return negativeLocationsIds_.getLong(index);
}
/**
*
* Optional. Current campaign negative location ids.
* One of this field OR positive_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 negative_locations_ids = 16 [(.google.api.field_behavior) = OPTIONAL];
* @param index The index to set the value at.
* @param value The negativeLocationsIds to set.
* @return This builder for chaining.
*/
public Builder setNegativeLocationsIds(
int index, long value) {
ensureNegativeLocationsIdsIsMutable();
negativeLocationsIds_.setLong(index, value);
bitField0_ |= 0x00004000;
onChanged();
return this;
}
/**
*
* Optional. Current campaign negative location ids.
* One of this field OR positive_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 negative_locations_ids = 16 [(.google.api.field_behavior) = OPTIONAL];
* @param value The negativeLocationsIds to add.
* @return This builder for chaining.
*/
public Builder addNegativeLocationsIds(long value) {
ensureNegativeLocationsIdsIsMutable();
negativeLocationsIds_.addLong(value);
bitField0_ |= 0x00004000;
onChanged();
return this;
}
/**
*
* Optional. Current campaign negative location ids.
* One of this field OR positive_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 negative_locations_ids = 16 [(.google.api.field_behavior) = OPTIONAL];
* @param values The negativeLocationsIds to add.
* @return This builder for chaining.
*/
public Builder addAllNegativeLocationsIds(
java.lang.Iterable extends java.lang.Long> values) {
ensureNegativeLocationsIdsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, negativeLocationsIds_);
bitField0_ |= 0x00004000;
onChanged();
return this;
}
/**
*
* Optional. Current campaign negative location ids.
* One of this field OR positive_location_ids is required for the following
* recommendation_types: CAMPAIGN_BUDGET if AdvertisingChannelType is SEARCH
*
*
* repeated int64 negative_locations_ids = 16 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearNegativeLocationsIds() {
negativeLocationsIds_ = emptyLongList();
bitField0_ = (bitField0_ & ~0x00004000);
onChanged();
return this;
}
private java.util.List assetGroupInfo_ =
java.util.Collections.emptyList();
private void ensureAssetGroupInfoIsMutable() {
if (!((bitField0_ & 0x00008000) != 0)) {
assetGroupInfo_ = new java.util.ArrayList(assetGroupInfo_);
bitField0_ |= 0x00008000;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfoOrBuilder> assetGroupInfoBuilder_;
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public java.util.List getAssetGroupInfoList() {
if (assetGroupInfoBuilder_ == null) {
return java.util.Collections.unmodifiableList(assetGroupInfo_);
} else {
return assetGroupInfoBuilder_.getMessageList();
}
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public int getAssetGroupInfoCount() {
if (assetGroupInfoBuilder_ == null) {
return assetGroupInfo_.size();
} else {
return assetGroupInfoBuilder_.getCount();
}
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo getAssetGroupInfo(int index) {
if (assetGroupInfoBuilder_ == null) {
return assetGroupInfo_.get(index);
} else {
return assetGroupInfoBuilder_.getMessage(index);
}
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setAssetGroupInfo(
int index, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo value) {
if (assetGroupInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAssetGroupInfoIsMutable();
assetGroupInfo_.set(index, value);
onChanged();
} else {
assetGroupInfoBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder setAssetGroupInfo(
int index, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder builderForValue) {
if (assetGroupInfoBuilder_ == null) {
ensureAssetGroupInfoIsMutable();
assetGroupInfo_.set(index, builderForValue.build());
onChanged();
} else {
assetGroupInfoBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAssetGroupInfo(com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo value) {
if (assetGroupInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAssetGroupInfoIsMutable();
assetGroupInfo_.add(value);
onChanged();
} else {
assetGroupInfoBuilder_.addMessage(value);
}
return this;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAssetGroupInfo(
int index, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo value) {
if (assetGroupInfoBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAssetGroupInfoIsMutable();
assetGroupInfo_.add(index, value);
onChanged();
} else {
assetGroupInfoBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAssetGroupInfo(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder builderForValue) {
if (assetGroupInfoBuilder_ == null) {
ensureAssetGroupInfoIsMutable();
assetGroupInfo_.add(builderForValue.build());
onChanged();
} else {
assetGroupInfoBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAssetGroupInfo(
int index, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder builderForValue) {
if (assetGroupInfoBuilder_ == null) {
ensureAssetGroupInfoIsMutable();
assetGroupInfo_.add(index, builderForValue.build());
onChanged();
} else {
assetGroupInfoBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder addAllAssetGroupInfo(
java.lang.Iterable extends com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo> values) {
if (assetGroupInfoBuilder_ == null) {
ensureAssetGroupInfoIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, assetGroupInfo_);
onChanged();
} else {
assetGroupInfoBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder clearAssetGroupInfo() {
if (assetGroupInfoBuilder_ == null) {
assetGroupInfo_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00008000);
onChanged();
} else {
assetGroupInfoBuilder_.clear();
}
return this;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public Builder removeAssetGroupInfo(int index) {
if (assetGroupInfoBuilder_ == null) {
ensureAssetGroupInfoIsMutable();
assetGroupInfo_.remove(index);
onChanged();
} else {
assetGroupInfoBuilder_.remove(index);
}
return this;
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder getAssetGroupInfoBuilder(
int index) {
return getAssetGroupInfoFieldBuilder().getBuilder(index);
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfoOrBuilder getAssetGroupInfoOrBuilder(
int index) {
if (assetGroupInfoBuilder_ == null) {
return assetGroupInfo_.get(index); } else {
return assetGroupInfoBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public java.util.List extends com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfoOrBuilder>
getAssetGroupInfoOrBuilderList() {
if (assetGroupInfoBuilder_ != null) {
return assetGroupInfoBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(assetGroupInfo_);
}
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder addAssetGroupInfoBuilder() {
return getAssetGroupInfoFieldBuilder().addBuilder(
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.getDefaultInstance());
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder addAssetGroupInfoBuilder(
int index) {
return getAssetGroupInfoFieldBuilder().addBuilder(
index, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.getDefaultInstance());
}
/**
*
* Optional. Current AssetGroup Information.
* This field is required for the following recommendation_types:
* CAMPAIGN_BUDGET
*
*
* repeated .google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo asset_group_info = 17 [(.google.api.field_behavior) = OPTIONAL];
*/
public java.util.List
getAssetGroupInfoBuilderList() {
return getAssetGroupInfoFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfoOrBuilder>
getAssetGroupInfoFieldBuilder() {
if (assetGroupInfoBuilder_ == null) {
assetGroupInfoBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfo.Builder, com.google.ads.googleads.v18.services.GenerateRecommendationsRequest.AssetGroupInfoOrBuilder>(
assetGroupInfo_,
((bitField0_ & 0x00008000) != 0),
getParentForChildren(),
isClean());
assetGroupInfo_ = null;
}
return assetGroupInfoBuilder_;
}
private boolean targetPartnerSearchNetwork_ ;
/**
*
* Optional. If true, the campaign is opted into serving ads on the Google
* Partner Network. This field is optional for the following
* recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_partner_search_network = 18 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the targetPartnerSearchNetwork field is set.
*/
@java.lang.Override
public boolean hasTargetPartnerSearchNetwork() {
return ((bitField0_ & 0x00010000) != 0);
}
/**
*
* Optional. If true, the campaign is opted into serving ads on the Google
* Partner Network. This field is optional for the following
* recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_partner_search_network = 18 [(.google.api.field_behavior) = OPTIONAL];
* @return The targetPartnerSearchNetwork.
*/
@java.lang.Override
public boolean getTargetPartnerSearchNetwork() {
return targetPartnerSearchNetwork_;
}
/**
*
* Optional. If true, the campaign is opted into serving ads on the Google
* Partner Network. This field is optional for the following
* recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_partner_search_network = 18 [(.google.api.field_behavior) = OPTIONAL];
* @param value The targetPartnerSearchNetwork to set.
* @return This builder for chaining.
*/
public Builder setTargetPartnerSearchNetwork(boolean value) {
targetPartnerSearchNetwork_ = value;
bitField0_ |= 0x00010000;
onChanged();
return this;
}
/**
*
* Optional. If true, the campaign is opted into serving ads on the Google
* Partner Network. This field is optional for the following
* recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_partner_search_network = 18 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearTargetPartnerSearchNetwork() {
bitField0_ = (bitField0_ & ~0x00010000);
targetPartnerSearchNetwork_ = false;
onChanged();
return this;
}
private boolean targetContentNetwork_ ;
/**
*
* Optional. If true, the campaign is opted into serving ads on specified
* placements in the Google Display Network. This field is optional for the
* following recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_content_network = 19 [(.google.api.field_behavior) = OPTIONAL];
* @return Whether the targetContentNetwork field is set.
*/
@java.lang.Override
public boolean hasTargetContentNetwork() {
return ((bitField0_ & 0x00020000) != 0);
}
/**
*
* Optional. If true, the campaign is opted into serving ads on specified
* placements in the Google Display Network. This field is optional for the
* following recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_content_network = 19 [(.google.api.field_behavior) = OPTIONAL];
* @return The targetContentNetwork.
*/
@java.lang.Override
public boolean getTargetContentNetwork() {
return targetContentNetwork_;
}
/**
*
* Optional. If true, the campaign is opted into serving ads on specified
* placements in the Google Display Network. This field is optional for the
* following recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_content_network = 19 [(.google.api.field_behavior) = OPTIONAL];
* @param value The targetContentNetwork to set.
* @return This builder for chaining.
*/
public Builder setTargetContentNetwork(boolean value) {
targetContentNetwork_ = value;
bitField0_ |= 0x00020000;
onChanged();
return this;
}
/**
*
* Optional. If true, the campaign is opted into serving ads on specified
* placements in the Google Display Network. This field is optional for the
* following recommendation_types: CAMPAIGN_BUDGET
*
*
* optional bool target_content_network = 19 [(.google.api.field_behavior) = OPTIONAL];
* @return This builder for chaining.
*/
public Builder clearTargetContentNetwork() {
bitField0_ = (bitField0_ & ~0x00020000);
targetContentNetwork_ = false;
onChanged();
return this;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFields(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest)
}
// @@protoc_insertion_point(class_scope:google.ads.googleads.v18.services.GenerateRecommendationsRequest)
private static final com.google.ads.googleads.v18.services.GenerateRecommendationsRequest DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.ads.googleads.v18.services.GenerateRecommendationsRequest();
}
public static com.google.ads.googleads.v18.services.GenerateRecommendationsRequest getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public GenerateRecommendationsRequest parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
Builder builder = newBuilder();
try {
builder.mergeFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(builder.buildPartial());
} catch (com.google.protobuf.UninitializedMessageException e) {
throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial());
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(e)
.setUnfinishedMessage(builder.buildPartial());
}
return builder.buildPartial();
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public com.google.ads.googleads.v18.services.GenerateRecommendationsRequest getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy