com.google.ads.googleads.v17.services.BasicInsightsAudience Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of google-ads-stubs-v17 Show documentation
Show all versions of google-ads-stubs-v17 Show documentation
Stubs for GAAPI version google-ads-stubs-v17
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/ads/googleads/v17/services/audience_insights_service.proto
// Protobuf Java Version: 3.25.3
package com.google.ads.googleads.v17.services;
/**
*
* A description of an audience used for requesting insights.
*
*
* Protobuf type {@code google.ads.googleads.v17.services.BasicInsightsAudience}
*/
public final class BasicInsightsAudience extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:google.ads.googleads.v17.services.BasicInsightsAudience)
BasicInsightsAudienceOrBuilder {
private static final long serialVersionUID = 0L;
// Use BasicInsightsAudience.newBuilder() to construct.
private BasicInsightsAudience(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private BasicInsightsAudience() {
countryLocation_ = java.util.Collections.emptyList();
subCountryLocations_ = java.util.Collections.emptyList();
ageRanges_ = java.util.Collections.emptyList();
userInterests_ = java.util.Collections.emptyList();
topics_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new BasicInsightsAudience();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v17.services.AudienceInsightsServiceProto.internal_static_google_ads_googleads_v17_services_BasicInsightsAudience_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v17.services.AudienceInsightsServiceProto.internal_static_google_ads_googleads_v17_services_BasicInsightsAudience_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v17.services.BasicInsightsAudience.class, com.google.ads.googleads.v17.services.BasicInsightsAudience.Builder.class);
}
private int bitField0_;
public static final int COUNTRY_LOCATION_FIELD_NUMBER = 1;
@SuppressWarnings("serial")
private java.util.List countryLocation_;
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
@java.lang.Override
public java.util.List getCountryLocationList() {
return countryLocation_;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
@java.lang.Override
public java.util.List extends com.google.ads.googleads.v17.common.LocationInfoOrBuilder>
getCountryLocationOrBuilderList() {
return countryLocation_;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
@java.lang.Override
public int getCountryLocationCount() {
return countryLocation_.size();
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
@java.lang.Override
public com.google.ads.googleads.v17.common.LocationInfo getCountryLocation(int index) {
return countryLocation_.get(index);
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
@java.lang.Override
public com.google.ads.googleads.v17.common.LocationInfoOrBuilder getCountryLocationOrBuilder(
int index) {
return countryLocation_.get(index);
}
public static final int SUB_COUNTRY_LOCATIONS_FIELD_NUMBER = 2;
@SuppressWarnings("serial")
private java.util.List subCountryLocations_;
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
@java.lang.Override
public java.util.List getSubCountryLocationsList() {
return subCountryLocations_;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
@java.lang.Override
public java.util.List extends com.google.ads.googleads.v17.common.LocationInfoOrBuilder>
getSubCountryLocationsOrBuilderList() {
return subCountryLocations_;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
@java.lang.Override
public int getSubCountryLocationsCount() {
return subCountryLocations_.size();
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
@java.lang.Override
public com.google.ads.googleads.v17.common.LocationInfo getSubCountryLocations(int index) {
return subCountryLocations_.get(index);
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
@java.lang.Override
public com.google.ads.googleads.v17.common.LocationInfoOrBuilder getSubCountryLocationsOrBuilder(
int index) {
return subCountryLocations_.get(index);
}
public static final int GENDER_FIELD_NUMBER = 3;
private com.google.ads.googleads.v17.common.GenderInfo gender_;
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
* @return Whether the gender field is set.
*/
@java.lang.Override
public boolean hasGender() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
* @return The gender.
*/
@java.lang.Override
public com.google.ads.googleads.v17.common.GenderInfo getGender() {
return gender_ == null ? com.google.ads.googleads.v17.common.GenderInfo.getDefaultInstance() : gender_;
}
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
*/
@java.lang.Override
public com.google.ads.googleads.v17.common.GenderInfoOrBuilder getGenderOrBuilder() {
return gender_ == null ? com.google.ads.googleads.v17.common.GenderInfo.getDefaultInstance() : gender_;
}
public static final int AGE_RANGES_FIELD_NUMBER = 4;
@SuppressWarnings("serial")
private java.util.List ageRanges_;
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
@java.lang.Override
public java.util.List getAgeRangesList() {
return ageRanges_;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
@java.lang.Override
public java.util.List extends com.google.ads.googleads.v17.common.AgeRangeInfoOrBuilder>
getAgeRangesOrBuilderList() {
return ageRanges_;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
@java.lang.Override
public int getAgeRangesCount() {
return ageRanges_.size();
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
@java.lang.Override
public com.google.ads.googleads.v17.common.AgeRangeInfo getAgeRanges(int index) {
return ageRanges_.get(index);
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
@java.lang.Override
public com.google.ads.googleads.v17.common.AgeRangeInfoOrBuilder getAgeRangesOrBuilder(
int index) {
return ageRanges_.get(index);
}
public static final int USER_INTERESTS_FIELD_NUMBER = 5;
@SuppressWarnings("serial")
private java.util.List userInterests_;
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
@java.lang.Override
public java.util.List getUserInterestsList() {
return userInterests_;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
@java.lang.Override
public java.util.List extends com.google.ads.googleads.v17.common.UserInterestInfoOrBuilder>
getUserInterestsOrBuilderList() {
return userInterests_;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
@java.lang.Override
public int getUserInterestsCount() {
return userInterests_.size();
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
@java.lang.Override
public com.google.ads.googleads.v17.common.UserInterestInfo getUserInterests(int index) {
return userInterests_.get(index);
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
@java.lang.Override
public com.google.ads.googleads.v17.common.UserInterestInfoOrBuilder getUserInterestsOrBuilder(
int index) {
return userInterests_.get(index);
}
public static final int TOPICS_FIELD_NUMBER = 6;
@SuppressWarnings("serial")
private java.util.List topics_;
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
@java.lang.Override
public java.util.List getTopicsList() {
return topics_;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
@java.lang.Override
public java.util.List extends com.google.ads.googleads.v17.services.AudienceInsightsTopicOrBuilder>
getTopicsOrBuilderList() {
return topics_;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
@java.lang.Override
public int getTopicsCount() {
return topics_.size();
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
@java.lang.Override
public com.google.ads.googleads.v17.services.AudienceInsightsTopic getTopics(int index) {
return topics_.get(index);
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
@java.lang.Override
public com.google.ads.googleads.v17.services.AudienceInsightsTopicOrBuilder getTopicsOrBuilder(
int index) {
return topics_.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 {
for (int i = 0; i < countryLocation_.size(); i++) {
output.writeMessage(1, countryLocation_.get(i));
}
for (int i = 0; i < subCountryLocations_.size(); i++) {
output.writeMessage(2, subCountryLocations_.get(i));
}
if (((bitField0_ & 0x00000001) != 0)) {
output.writeMessage(3, getGender());
}
for (int i = 0; i < ageRanges_.size(); i++) {
output.writeMessage(4, ageRanges_.get(i));
}
for (int i = 0; i < userInterests_.size(); i++) {
output.writeMessage(5, userInterests_.get(i));
}
for (int i = 0; i < topics_.size(); i++) {
output.writeMessage(6, topics_.get(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
for (int i = 0; i < countryLocation_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, countryLocation_.get(i));
}
for (int i = 0; i < subCountryLocations_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, subCountryLocations_.get(i));
}
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getGender());
}
for (int i = 0; i < ageRanges_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(4, ageRanges_.get(i));
}
for (int i = 0; i < userInterests_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(5, userInterests_.get(i));
}
for (int i = 0; i < topics_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(6, topics_.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.v17.services.BasicInsightsAudience)) {
return super.equals(obj);
}
com.google.ads.googleads.v17.services.BasicInsightsAudience other = (com.google.ads.googleads.v17.services.BasicInsightsAudience) obj;
if (!getCountryLocationList()
.equals(other.getCountryLocationList())) return false;
if (!getSubCountryLocationsList()
.equals(other.getSubCountryLocationsList())) return false;
if (hasGender() != other.hasGender()) return false;
if (hasGender()) {
if (!getGender()
.equals(other.getGender())) return false;
}
if (!getAgeRangesList()
.equals(other.getAgeRangesList())) return false;
if (!getUserInterestsList()
.equals(other.getUserInterestsList())) return false;
if (!getTopicsList()
.equals(other.getTopicsList())) 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 (getCountryLocationCount() > 0) {
hash = (37 * hash) + COUNTRY_LOCATION_FIELD_NUMBER;
hash = (53 * hash) + getCountryLocationList().hashCode();
}
if (getSubCountryLocationsCount() > 0) {
hash = (37 * hash) + SUB_COUNTRY_LOCATIONS_FIELD_NUMBER;
hash = (53 * hash) + getSubCountryLocationsList().hashCode();
}
if (hasGender()) {
hash = (37 * hash) + GENDER_FIELD_NUMBER;
hash = (53 * hash) + getGender().hashCode();
}
if (getAgeRangesCount() > 0) {
hash = (37 * hash) + AGE_RANGES_FIELD_NUMBER;
hash = (53 * hash) + getAgeRangesList().hashCode();
}
if (getUserInterestsCount() > 0) {
hash = (37 * hash) + USER_INTERESTS_FIELD_NUMBER;
hash = (53 * hash) + getUserInterestsList().hashCode();
}
if (getTopicsCount() > 0) {
hash = (37 * hash) + TOPICS_FIELD_NUMBER;
hash = (53 * hash) + getTopicsList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.ads.googleads.v17.services.BasicInsightsAudience parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v17.services.BasicInsightsAudience 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.v17.services.BasicInsightsAudience parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v17.services.BasicInsightsAudience 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.v17.services.BasicInsightsAudience parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v17.services.BasicInsightsAudience parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v17.services.BasicInsightsAudience parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v17.services.BasicInsightsAudience 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.v17.services.BasicInsightsAudience parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v17.services.BasicInsightsAudience 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.v17.services.BasicInsightsAudience parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v17.services.BasicInsightsAudience 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.v17.services.BasicInsightsAudience 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 description of an audience used for requesting insights.
*
*
* Protobuf type {@code google.ads.googleads.v17.services.BasicInsightsAudience}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:google.ads.googleads.v17.services.BasicInsightsAudience)
com.google.ads.googleads.v17.services.BasicInsightsAudienceOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v17.services.AudienceInsightsServiceProto.internal_static_google_ads_googleads_v17_services_BasicInsightsAudience_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v17.services.AudienceInsightsServiceProto.internal_static_google_ads_googleads_v17_services_BasicInsightsAudience_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v17.services.BasicInsightsAudience.class, com.google.ads.googleads.v17.services.BasicInsightsAudience.Builder.class);
}
// Construct using com.google.ads.googleads.v17.services.BasicInsightsAudience.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getCountryLocationFieldBuilder();
getSubCountryLocationsFieldBuilder();
getGenderFieldBuilder();
getAgeRangesFieldBuilder();
getUserInterestsFieldBuilder();
getTopicsFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (countryLocationBuilder_ == null) {
countryLocation_ = java.util.Collections.emptyList();
} else {
countryLocation_ = null;
countryLocationBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000001);
if (subCountryLocationsBuilder_ == null) {
subCountryLocations_ = java.util.Collections.emptyList();
} else {
subCountryLocations_ = null;
subCountryLocationsBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000002);
gender_ = null;
if (genderBuilder_ != null) {
genderBuilder_.dispose();
genderBuilder_ = null;
}
if (ageRangesBuilder_ == null) {
ageRanges_ = java.util.Collections.emptyList();
} else {
ageRanges_ = null;
ageRangesBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000008);
if (userInterestsBuilder_ == null) {
userInterests_ = java.util.Collections.emptyList();
} else {
userInterests_ = null;
userInterestsBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000010);
if (topicsBuilder_ == null) {
topics_ = java.util.Collections.emptyList();
} else {
topics_ = null;
topicsBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000020);
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.ads.googleads.v17.services.AudienceInsightsServiceProto.internal_static_google_ads_googleads_v17_services_BasicInsightsAudience_descriptor;
}
@java.lang.Override
public com.google.ads.googleads.v17.services.BasicInsightsAudience getDefaultInstanceForType() {
return com.google.ads.googleads.v17.services.BasicInsightsAudience.getDefaultInstance();
}
@java.lang.Override
public com.google.ads.googleads.v17.services.BasicInsightsAudience build() {
com.google.ads.googleads.v17.services.BasicInsightsAudience result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.ads.googleads.v17.services.BasicInsightsAudience buildPartial() {
com.google.ads.googleads.v17.services.BasicInsightsAudience result = new com.google.ads.googleads.v17.services.BasicInsightsAudience(this);
buildPartialRepeatedFields(result);
if (bitField0_ != 0) { buildPartial0(result); }
onBuilt();
return result;
}
private void buildPartialRepeatedFields(com.google.ads.googleads.v17.services.BasicInsightsAudience result) {
if (countryLocationBuilder_ == null) {
if (((bitField0_ & 0x00000001) != 0)) {
countryLocation_ = java.util.Collections.unmodifiableList(countryLocation_);
bitField0_ = (bitField0_ & ~0x00000001);
}
result.countryLocation_ = countryLocation_;
} else {
result.countryLocation_ = countryLocationBuilder_.build();
}
if (subCountryLocationsBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0)) {
subCountryLocations_ = java.util.Collections.unmodifiableList(subCountryLocations_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.subCountryLocations_ = subCountryLocations_;
} else {
result.subCountryLocations_ = subCountryLocationsBuilder_.build();
}
if (ageRangesBuilder_ == null) {
if (((bitField0_ & 0x00000008) != 0)) {
ageRanges_ = java.util.Collections.unmodifiableList(ageRanges_);
bitField0_ = (bitField0_ & ~0x00000008);
}
result.ageRanges_ = ageRanges_;
} else {
result.ageRanges_ = ageRangesBuilder_.build();
}
if (userInterestsBuilder_ == null) {
if (((bitField0_ & 0x00000010) != 0)) {
userInterests_ = java.util.Collections.unmodifiableList(userInterests_);
bitField0_ = (bitField0_ & ~0x00000010);
}
result.userInterests_ = userInterests_;
} else {
result.userInterests_ = userInterestsBuilder_.build();
}
if (topicsBuilder_ == null) {
if (((bitField0_ & 0x00000020) != 0)) {
topics_ = java.util.Collections.unmodifiableList(topics_);
bitField0_ = (bitField0_ & ~0x00000020);
}
result.topics_ = topics_;
} else {
result.topics_ = topicsBuilder_.build();
}
}
private void buildPartial0(com.google.ads.googleads.v17.services.BasicInsightsAudience result) {
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000004) != 0)) {
result.gender_ = genderBuilder_ == null
? gender_
: genderBuilder_.build();
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.v17.services.BasicInsightsAudience) {
return mergeFrom((com.google.ads.googleads.v17.services.BasicInsightsAudience)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.ads.googleads.v17.services.BasicInsightsAudience other) {
if (other == com.google.ads.googleads.v17.services.BasicInsightsAudience.getDefaultInstance()) return this;
if (countryLocationBuilder_ == null) {
if (!other.countryLocation_.isEmpty()) {
if (countryLocation_.isEmpty()) {
countryLocation_ = other.countryLocation_;
bitField0_ = (bitField0_ & ~0x00000001);
} else {
ensureCountryLocationIsMutable();
countryLocation_.addAll(other.countryLocation_);
}
onChanged();
}
} else {
if (!other.countryLocation_.isEmpty()) {
if (countryLocationBuilder_.isEmpty()) {
countryLocationBuilder_.dispose();
countryLocationBuilder_ = null;
countryLocation_ = other.countryLocation_;
bitField0_ = (bitField0_ & ~0x00000001);
countryLocationBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getCountryLocationFieldBuilder() : null;
} else {
countryLocationBuilder_.addAllMessages(other.countryLocation_);
}
}
}
if (subCountryLocationsBuilder_ == null) {
if (!other.subCountryLocations_.isEmpty()) {
if (subCountryLocations_.isEmpty()) {
subCountryLocations_ = other.subCountryLocations_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureSubCountryLocationsIsMutable();
subCountryLocations_.addAll(other.subCountryLocations_);
}
onChanged();
}
} else {
if (!other.subCountryLocations_.isEmpty()) {
if (subCountryLocationsBuilder_.isEmpty()) {
subCountryLocationsBuilder_.dispose();
subCountryLocationsBuilder_ = null;
subCountryLocations_ = other.subCountryLocations_;
bitField0_ = (bitField0_ & ~0x00000002);
subCountryLocationsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getSubCountryLocationsFieldBuilder() : null;
} else {
subCountryLocationsBuilder_.addAllMessages(other.subCountryLocations_);
}
}
}
if (other.hasGender()) {
mergeGender(other.getGender());
}
if (ageRangesBuilder_ == null) {
if (!other.ageRanges_.isEmpty()) {
if (ageRanges_.isEmpty()) {
ageRanges_ = other.ageRanges_;
bitField0_ = (bitField0_ & ~0x00000008);
} else {
ensureAgeRangesIsMutable();
ageRanges_.addAll(other.ageRanges_);
}
onChanged();
}
} else {
if (!other.ageRanges_.isEmpty()) {
if (ageRangesBuilder_.isEmpty()) {
ageRangesBuilder_.dispose();
ageRangesBuilder_ = null;
ageRanges_ = other.ageRanges_;
bitField0_ = (bitField0_ & ~0x00000008);
ageRangesBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getAgeRangesFieldBuilder() : null;
} else {
ageRangesBuilder_.addAllMessages(other.ageRanges_);
}
}
}
if (userInterestsBuilder_ == null) {
if (!other.userInterests_.isEmpty()) {
if (userInterests_.isEmpty()) {
userInterests_ = other.userInterests_;
bitField0_ = (bitField0_ & ~0x00000010);
} else {
ensureUserInterestsIsMutable();
userInterests_.addAll(other.userInterests_);
}
onChanged();
}
} else {
if (!other.userInterests_.isEmpty()) {
if (userInterestsBuilder_.isEmpty()) {
userInterestsBuilder_.dispose();
userInterestsBuilder_ = null;
userInterests_ = other.userInterests_;
bitField0_ = (bitField0_ & ~0x00000010);
userInterestsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getUserInterestsFieldBuilder() : null;
} else {
userInterestsBuilder_.addAllMessages(other.userInterests_);
}
}
}
if (topicsBuilder_ == null) {
if (!other.topics_.isEmpty()) {
if (topics_.isEmpty()) {
topics_ = other.topics_;
bitField0_ = (bitField0_ & ~0x00000020);
} else {
ensureTopicsIsMutable();
topics_.addAll(other.topics_);
}
onChanged();
}
} else {
if (!other.topics_.isEmpty()) {
if (topicsBuilder_.isEmpty()) {
topicsBuilder_.dispose();
topicsBuilder_ = null;
topics_ = other.topics_;
bitField0_ = (bitField0_ & ~0x00000020);
topicsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getTopicsFieldBuilder() : null;
} else {
topicsBuilder_.addAllMessages(other.topics_);
}
}
}
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: {
com.google.ads.googleads.v17.common.LocationInfo m =
input.readMessage(
com.google.ads.googleads.v17.common.LocationInfo.parser(),
extensionRegistry);
if (countryLocationBuilder_ == null) {
ensureCountryLocationIsMutable();
countryLocation_.add(m);
} else {
countryLocationBuilder_.addMessage(m);
}
break;
} // case 10
case 18: {
com.google.ads.googleads.v17.common.LocationInfo m =
input.readMessage(
com.google.ads.googleads.v17.common.LocationInfo.parser(),
extensionRegistry);
if (subCountryLocationsBuilder_ == null) {
ensureSubCountryLocationsIsMutable();
subCountryLocations_.add(m);
} else {
subCountryLocationsBuilder_.addMessage(m);
}
break;
} // case 18
case 26: {
input.readMessage(
getGenderFieldBuilder().getBuilder(),
extensionRegistry);
bitField0_ |= 0x00000004;
break;
} // case 26
case 34: {
com.google.ads.googleads.v17.common.AgeRangeInfo m =
input.readMessage(
com.google.ads.googleads.v17.common.AgeRangeInfo.parser(),
extensionRegistry);
if (ageRangesBuilder_ == null) {
ensureAgeRangesIsMutable();
ageRanges_.add(m);
} else {
ageRangesBuilder_.addMessage(m);
}
break;
} // case 34
case 42: {
com.google.ads.googleads.v17.common.UserInterestInfo m =
input.readMessage(
com.google.ads.googleads.v17.common.UserInterestInfo.parser(),
extensionRegistry);
if (userInterestsBuilder_ == null) {
ensureUserInterestsIsMutable();
userInterests_.add(m);
} else {
userInterestsBuilder_.addMessage(m);
}
break;
} // case 42
case 50: {
com.google.ads.googleads.v17.services.AudienceInsightsTopic m =
input.readMessage(
com.google.ads.googleads.v17.services.AudienceInsightsTopic.parser(),
extensionRegistry);
if (topicsBuilder_ == null) {
ensureTopicsIsMutable();
topics_.add(m);
} else {
topicsBuilder_.addMessage(m);
}
break;
} // case 50
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.util.List countryLocation_ =
java.util.Collections.emptyList();
private void ensureCountryLocationIsMutable() {
if (!((bitField0_ & 0x00000001) != 0)) {
countryLocation_ = new java.util.ArrayList(countryLocation_);
bitField0_ |= 0x00000001;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.LocationInfo, com.google.ads.googleads.v17.common.LocationInfo.Builder, com.google.ads.googleads.v17.common.LocationInfoOrBuilder> countryLocationBuilder_;
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public java.util.List getCountryLocationList() {
if (countryLocationBuilder_ == null) {
return java.util.Collections.unmodifiableList(countryLocation_);
} else {
return countryLocationBuilder_.getMessageList();
}
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public int getCountryLocationCount() {
if (countryLocationBuilder_ == null) {
return countryLocation_.size();
} else {
return countryLocationBuilder_.getCount();
}
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public com.google.ads.googleads.v17.common.LocationInfo getCountryLocation(int index) {
if (countryLocationBuilder_ == null) {
return countryLocation_.get(index);
} else {
return countryLocationBuilder_.getMessage(index);
}
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public Builder setCountryLocation(
int index, com.google.ads.googleads.v17.common.LocationInfo value) {
if (countryLocationBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCountryLocationIsMutable();
countryLocation_.set(index, value);
onChanged();
} else {
countryLocationBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public Builder setCountryLocation(
int index, com.google.ads.googleads.v17.common.LocationInfo.Builder builderForValue) {
if (countryLocationBuilder_ == null) {
ensureCountryLocationIsMutable();
countryLocation_.set(index, builderForValue.build());
onChanged();
} else {
countryLocationBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public Builder addCountryLocation(com.google.ads.googleads.v17.common.LocationInfo value) {
if (countryLocationBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCountryLocationIsMutable();
countryLocation_.add(value);
onChanged();
} else {
countryLocationBuilder_.addMessage(value);
}
return this;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public Builder addCountryLocation(
int index, com.google.ads.googleads.v17.common.LocationInfo value) {
if (countryLocationBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureCountryLocationIsMutable();
countryLocation_.add(index, value);
onChanged();
} else {
countryLocationBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public Builder addCountryLocation(
com.google.ads.googleads.v17.common.LocationInfo.Builder builderForValue) {
if (countryLocationBuilder_ == null) {
ensureCountryLocationIsMutable();
countryLocation_.add(builderForValue.build());
onChanged();
} else {
countryLocationBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public Builder addCountryLocation(
int index, com.google.ads.googleads.v17.common.LocationInfo.Builder builderForValue) {
if (countryLocationBuilder_ == null) {
ensureCountryLocationIsMutable();
countryLocation_.add(index, builderForValue.build());
onChanged();
} else {
countryLocationBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public Builder addAllCountryLocation(
java.lang.Iterable extends com.google.ads.googleads.v17.common.LocationInfo> values) {
if (countryLocationBuilder_ == null) {
ensureCountryLocationIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, countryLocation_);
onChanged();
} else {
countryLocationBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public Builder clearCountryLocation() {
if (countryLocationBuilder_ == null) {
countryLocation_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000001);
onChanged();
} else {
countryLocationBuilder_.clear();
}
return this;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public Builder removeCountryLocation(int index) {
if (countryLocationBuilder_ == null) {
ensureCountryLocationIsMutable();
countryLocation_.remove(index);
onChanged();
} else {
countryLocationBuilder_.remove(index);
}
return this;
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public com.google.ads.googleads.v17.common.LocationInfo.Builder getCountryLocationBuilder(
int index) {
return getCountryLocationFieldBuilder().getBuilder(index);
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public com.google.ads.googleads.v17.common.LocationInfoOrBuilder getCountryLocationOrBuilder(
int index) {
if (countryLocationBuilder_ == null) {
return countryLocation_.get(index); } else {
return countryLocationBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public java.util.List extends com.google.ads.googleads.v17.common.LocationInfoOrBuilder>
getCountryLocationOrBuilderList() {
if (countryLocationBuilder_ != null) {
return countryLocationBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(countryLocation_);
}
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public com.google.ads.googleads.v17.common.LocationInfo.Builder addCountryLocationBuilder() {
return getCountryLocationFieldBuilder().addBuilder(
com.google.ads.googleads.v17.common.LocationInfo.getDefaultInstance());
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public com.google.ads.googleads.v17.common.LocationInfo.Builder addCountryLocationBuilder(
int index) {
return getCountryLocationFieldBuilder().addBuilder(
index, com.google.ads.googleads.v17.common.LocationInfo.getDefaultInstance());
}
/**
*
* Required. The countries for this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo country_location = 1 [(.google.api.field_behavior) = REQUIRED];
*/
public java.util.List
getCountryLocationBuilderList() {
return getCountryLocationFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.LocationInfo, com.google.ads.googleads.v17.common.LocationInfo.Builder, com.google.ads.googleads.v17.common.LocationInfoOrBuilder>
getCountryLocationFieldBuilder() {
if (countryLocationBuilder_ == null) {
countryLocationBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.LocationInfo, com.google.ads.googleads.v17.common.LocationInfo.Builder, com.google.ads.googleads.v17.common.LocationInfoOrBuilder>(
countryLocation_,
((bitField0_ & 0x00000001) != 0),
getParentForChildren(),
isClean());
countryLocation_ = null;
}
return countryLocationBuilder_;
}
private java.util.List subCountryLocations_ =
java.util.Collections.emptyList();
private void ensureSubCountryLocationsIsMutable() {
if (!((bitField0_ & 0x00000002) != 0)) {
subCountryLocations_ = new java.util.ArrayList(subCountryLocations_);
bitField0_ |= 0x00000002;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.LocationInfo, com.google.ads.googleads.v17.common.LocationInfo.Builder, com.google.ads.googleads.v17.common.LocationInfoOrBuilder> subCountryLocationsBuilder_;
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public java.util.List getSubCountryLocationsList() {
if (subCountryLocationsBuilder_ == null) {
return java.util.Collections.unmodifiableList(subCountryLocations_);
} else {
return subCountryLocationsBuilder_.getMessageList();
}
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public int getSubCountryLocationsCount() {
if (subCountryLocationsBuilder_ == null) {
return subCountryLocations_.size();
} else {
return subCountryLocationsBuilder_.getCount();
}
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public com.google.ads.googleads.v17.common.LocationInfo getSubCountryLocations(int index) {
if (subCountryLocationsBuilder_ == null) {
return subCountryLocations_.get(index);
} else {
return subCountryLocationsBuilder_.getMessage(index);
}
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public Builder setSubCountryLocations(
int index, com.google.ads.googleads.v17.common.LocationInfo value) {
if (subCountryLocationsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureSubCountryLocationsIsMutable();
subCountryLocations_.set(index, value);
onChanged();
} else {
subCountryLocationsBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public Builder setSubCountryLocations(
int index, com.google.ads.googleads.v17.common.LocationInfo.Builder builderForValue) {
if (subCountryLocationsBuilder_ == null) {
ensureSubCountryLocationsIsMutable();
subCountryLocations_.set(index, builderForValue.build());
onChanged();
} else {
subCountryLocationsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public Builder addSubCountryLocations(com.google.ads.googleads.v17.common.LocationInfo value) {
if (subCountryLocationsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureSubCountryLocationsIsMutable();
subCountryLocations_.add(value);
onChanged();
} else {
subCountryLocationsBuilder_.addMessage(value);
}
return this;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public Builder addSubCountryLocations(
int index, com.google.ads.googleads.v17.common.LocationInfo value) {
if (subCountryLocationsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureSubCountryLocationsIsMutable();
subCountryLocations_.add(index, value);
onChanged();
} else {
subCountryLocationsBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public Builder addSubCountryLocations(
com.google.ads.googleads.v17.common.LocationInfo.Builder builderForValue) {
if (subCountryLocationsBuilder_ == null) {
ensureSubCountryLocationsIsMutable();
subCountryLocations_.add(builderForValue.build());
onChanged();
} else {
subCountryLocationsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public Builder addSubCountryLocations(
int index, com.google.ads.googleads.v17.common.LocationInfo.Builder builderForValue) {
if (subCountryLocationsBuilder_ == null) {
ensureSubCountryLocationsIsMutable();
subCountryLocations_.add(index, builderForValue.build());
onChanged();
} else {
subCountryLocationsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public Builder addAllSubCountryLocations(
java.lang.Iterable extends com.google.ads.googleads.v17.common.LocationInfo> values) {
if (subCountryLocationsBuilder_ == null) {
ensureSubCountryLocationsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, subCountryLocations_);
onChanged();
} else {
subCountryLocationsBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public Builder clearSubCountryLocations() {
if (subCountryLocationsBuilder_ == null) {
subCountryLocations_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
subCountryLocationsBuilder_.clear();
}
return this;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public Builder removeSubCountryLocations(int index) {
if (subCountryLocationsBuilder_ == null) {
ensureSubCountryLocationsIsMutable();
subCountryLocations_.remove(index);
onChanged();
} else {
subCountryLocationsBuilder_.remove(index);
}
return this;
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public com.google.ads.googleads.v17.common.LocationInfo.Builder getSubCountryLocationsBuilder(
int index) {
return getSubCountryLocationsFieldBuilder().getBuilder(index);
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public com.google.ads.googleads.v17.common.LocationInfoOrBuilder getSubCountryLocationsOrBuilder(
int index) {
if (subCountryLocationsBuilder_ == null) {
return subCountryLocations_.get(index); } else {
return subCountryLocationsBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public java.util.List extends com.google.ads.googleads.v17.common.LocationInfoOrBuilder>
getSubCountryLocationsOrBuilderList() {
if (subCountryLocationsBuilder_ != null) {
return subCountryLocationsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(subCountryLocations_);
}
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public com.google.ads.googleads.v17.common.LocationInfo.Builder addSubCountryLocationsBuilder() {
return getSubCountryLocationsFieldBuilder().addBuilder(
com.google.ads.googleads.v17.common.LocationInfo.getDefaultInstance());
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public com.google.ads.googleads.v17.common.LocationInfo.Builder addSubCountryLocationsBuilder(
int index) {
return getSubCountryLocationsFieldBuilder().addBuilder(
index, com.google.ads.googleads.v17.common.LocationInfo.getDefaultInstance());
}
/**
*
* Sub-country geographic location attributes. If present, each of these
* must be contained in one of the countries in this audience.
*
*
* repeated .google.ads.googleads.v17.common.LocationInfo sub_country_locations = 2;
*/
public java.util.List
getSubCountryLocationsBuilderList() {
return getSubCountryLocationsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.LocationInfo, com.google.ads.googleads.v17.common.LocationInfo.Builder, com.google.ads.googleads.v17.common.LocationInfoOrBuilder>
getSubCountryLocationsFieldBuilder() {
if (subCountryLocationsBuilder_ == null) {
subCountryLocationsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.LocationInfo, com.google.ads.googleads.v17.common.LocationInfo.Builder, com.google.ads.googleads.v17.common.LocationInfoOrBuilder>(
subCountryLocations_,
((bitField0_ & 0x00000002) != 0),
getParentForChildren(),
isClean());
subCountryLocations_ = null;
}
return subCountryLocationsBuilder_;
}
private com.google.ads.googleads.v17.common.GenderInfo gender_;
private com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v17.common.GenderInfo, com.google.ads.googleads.v17.common.GenderInfo.Builder, com.google.ads.googleads.v17.common.GenderInfoOrBuilder> genderBuilder_;
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
* @return Whether the gender field is set.
*/
public boolean hasGender() {
return ((bitField0_ & 0x00000004) != 0);
}
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
* @return The gender.
*/
public com.google.ads.googleads.v17.common.GenderInfo getGender() {
if (genderBuilder_ == null) {
return gender_ == null ? com.google.ads.googleads.v17.common.GenderInfo.getDefaultInstance() : gender_;
} else {
return genderBuilder_.getMessage();
}
}
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
*/
public Builder setGender(com.google.ads.googleads.v17.common.GenderInfo value) {
if (genderBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
gender_ = value;
} else {
genderBuilder_.setMessage(value);
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
*/
public Builder setGender(
com.google.ads.googleads.v17.common.GenderInfo.Builder builderForValue) {
if (genderBuilder_ == null) {
gender_ = builderForValue.build();
} else {
genderBuilder_.setMessage(builderForValue.build());
}
bitField0_ |= 0x00000004;
onChanged();
return this;
}
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
*/
public Builder mergeGender(com.google.ads.googleads.v17.common.GenderInfo value) {
if (genderBuilder_ == null) {
if (((bitField0_ & 0x00000004) != 0) &&
gender_ != null &&
gender_ != com.google.ads.googleads.v17.common.GenderInfo.getDefaultInstance()) {
getGenderBuilder().mergeFrom(value);
} else {
gender_ = value;
}
} else {
genderBuilder_.mergeFrom(value);
}
if (gender_ != null) {
bitField0_ |= 0x00000004;
onChanged();
}
return this;
}
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
*/
public Builder clearGender() {
bitField0_ = (bitField0_ & ~0x00000004);
gender_ = null;
if (genderBuilder_ != null) {
genderBuilder_.dispose();
genderBuilder_ = null;
}
onChanged();
return this;
}
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
*/
public com.google.ads.googleads.v17.common.GenderInfo.Builder getGenderBuilder() {
bitField0_ |= 0x00000004;
onChanged();
return getGenderFieldBuilder().getBuilder();
}
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
*/
public com.google.ads.googleads.v17.common.GenderInfoOrBuilder getGenderOrBuilder() {
if (genderBuilder_ != null) {
return genderBuilder_.getMessageOrBuilder();
} else {
return gender_ == null ?
com.google.ads.googleads.v17.common.GenderInfo.getDefaultInstance() : gender_;
}
}
/**
*
* Gender for the audience. If absent, the audience does not restrict by
* gender.
*
*
* .google.ads.googleads.v17.common.GenderInfo gender = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v17.common.GenderInfo, com.google.ads.googleads.v17.common.GenderInfo.Builder, com.google.ads.googleads.v17.common.GenderInfoOrBuilder>
getGenderFieldBuilder() {
if (genderBuilder_ == null) {
genderBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
com.google.ads.googleads.v17.common.GenderInfo, com.google.ads.googleads.v17.common.GenderInfo.Builder, com.google.ads.googleads.v17.common.GenderInfoOrBuilder>(
getGender(),
getParentForChildren(),
isClean());
gender_ = null;
}
return genderBuilder_;
}
private java.util.List ageRanges_ =
java.util.Collections.emptyList();
private void ensureAgeRangesIsMutable() {
if (!((bitField0_ & 0x00000008) != 0)) {
ageRanges_ = new java.util.ArrayList(ageRanges_);
bitField0_ |= 0x00000008;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.AgeRangeInfo, com.google.ads.googleads.v17.common.AgeRangeInfo.Builder, com.google.ads.googleads.v17.common.AgeRangeInfoOrBuilder> ageRangesBuilder_;
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public java.util.List getAgeRangesList() {
if (ageRangesBuilder_ == null) {
return java.util.Collections.unmodifiableList(ageRanges_);
} else {
return ageRangesBuilder_.getMessageList();
}
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public int getAgeRangesCount() {
if (ageRangesBuilder_ == null) {
return ageRanges_.size();
} else {
return ageRangesBuilder_.getCount();
}
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public com.google.ads.googleads.v17.common.AgeRangeInfo getAgeRanges(int index) {
if (ageRangesBuilder_ == null) {
return ageRanges_.get(index);
} else {
return ageRangesBuilder_.getMessage(index);
}
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public Builder setAgeRanges(
int index, com.google.ads.googleads.v17.common.AgeRangeInfo value) {
if (ageRangesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAgeRangesIsMutable();
ageRanges_.set(index, value);
onChanged();
} else {
ageRangesBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public Builder setAgeRanges(
int index, com.google.ads.googleads.v17.common.AgeRangeInfo.Builder builderForValue) {
if (ageRangesBuilder_ == null) {
ensureAgeRangesIsMutable();
ageRanges_.set(index, builderForValue.build());
onChanged();
} else {
ageRangesBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public Builder addAgeRanges(com.google.ads.googleads.v17.common.AgeRangeInfo value) {
if (ageRangesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAgeRangesIsMutable();
ageRanges_.add(value);
onChanged();
} else {
ageRangesBuilder_.addMessage(value);
}
return this;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public Builder addAgeRanges(
int index, com.google.ads.googleads.v17.common.AgeRangeInfo value) {
if (ageRangesBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureAgeRangesIsMutable();
ageRanges_.add(index, value);
onChanged();
} else {
ageRangesBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public Builder addAgeRanges(
com.google.ads.googleads.v17.common.AgeRangeInfo.Builder builderForValue) {
if (ageRangesBuilder_ == null) {
ensureAgeRangesIsMutable();
ageRanges_.add(builderForValue.build());
onChanged();
} else {
ageRangesBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public Builder addAgeRanges(
int index, com.google.ads.googleads.v17.common.AgeRangeInfo.Builder builderForValue) {
if (ageRangesBuilder_ == null) {
ensureAgeRangesIsMutable();
ageRanges_.add(index, builderForValue.build());
onChanged();
} else {
ageRangesBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public Builder addAllAgeRanges(
java.lang.Iterable extends com.google.ads.googleads.v17.common.AgeRangeInfo> values) {
if (ageRangesBuilder_ == null) {
ensureAgeRangesIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, ageRanges_);
onChanged();
} else {
ageRangesBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public Builder clearAgeRanges() {
if (ageRangesBuilder_ == null) {
ageRanges_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000008);
onChanged();
} else {
ageRangesBuilder_.clear();
}
return this;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public Builder removeAgeRanges(int index) {
if (ageRangesBuilder_ == null) {
ensureAgeRangesIsMutable();
ageRanges_.remove(index);
onChanged();
} else {
ageRangesBuilder_.remove(index);
}
return this;
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public com.google.ads.googleads.v17.common.AgeRangeInfo.Builder getAgeRangesBuilder(
int index) {
return getAgeRangesFieldBuilder().getBuilder(index);
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public com.google.ads.googleads.v17.common.AgeRangeInfoOrBuilder getAgeRangesOrBuilder(
int index) {
if (ageRangesBuilder_ == null) {
return ageRanges_.get(index); } else {
return ageRangesBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public java.util.List extends com.google.ads.googleads.v17.common.AgeRangeInfoOrBuilder>
getAgeRangesOrBuilderList() {
if (ageRangesBuilder_ != null) {
return ageRangesBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(ageRanges_);
}
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public com.google.ads.googleads.v17.common.AgeRangeInfo.Builder addAgeRangesBuilder() {
return getAgeRangesFieldBuilder().addBuilder(
com.google.ads.googleads.v17.common.AgeRangeInfo.getDefaultInstance());
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public com.google.ads.googleads.v17.common.AgeRangeInfo.Builder addAgeRangesBuilder(
int index) {
return getAgeRangesFieldBuilder().addBuilder(
index, com.google.ads.googleads.v17.common.AgeRangeInfo.getDefaultInstance());
}
/**
*
* Age ranges for the audience. If absent, the audience represents all people
* over 18 that match the other attributes.
*
*
* repeated .google.ads.googleads.v17.common.AgeRangeInfo age_ranges = 4;
*/
public java.util.List
getAgeRangesBuilderList() {
return getAgeRangesFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.AgeRangeInfo, com.google.ads.googleads.v17.common.AgeRangeInfo.Builder, com.google.ads.googleads.v17.common.AgeRangeInfoOrBuilder>
getAgeRangesFieldBuilder() {
if (ageRangesBuilder_ == null) {
ageRangesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.AgeRangeInfo, com.google.ads.googleads.v17.common.AgeRangeInfo.Builder, com.google.ads.googleads.v17.common.AgeRangeInfoOrBuilder>(
ageRanges_,
((bitField0_ & 0x00000008) != 0),
getParentForChildren(),
isClean());
ageRanges_ = null;
}
return ageRangesBuilder_;
}
private java.util.List userInterests_ =
java.util.Collections.emptyList();
private void ensureUserInterestsIsMutable() {
if (!((bitField0_ & 0x00000010) != 0)) {
userInterests_ = new java.util.ArrayList(userInterests_);
bitField0_ |= 0x00000010;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.UserInterestInfo, com.google.ads.googleads.v17.common.UserInterestInfo.Builder, com.google.ads.googleads.v17.common.UserInterestInfoOrBuilder> userInterestsBuilder_;
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public java.util.List getUserInterestsList() {
if (userInterestsBuilder_ == null) {
return java.util.Collections.unmodifiableList(userInterests_);
} else {
return userInterestsBuilder_.getMessageList();
}
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public int getUserInterestsCount() {
if (userInterestsBuilder_ == null) {
return userInterests_.size();
} else {
return userInterestsBuilder_.getCount();
}
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public com.google.ads.googleads.v17.common.UserInterestInfo getUserInterests(int index) {
if (userInterestsBuilder_ == null) {
return userInterests_.get(index);
} else {
return userInterestsBuilder_.getMessage(index);
}
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public Builder setUserInterests(
int index, com.google.ads.googleads.v17.common.UserInterestInfo value) {
if (userInterestsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureUserInterestsIsMutable();
userInterests_.set(index, value);
onChanged();
} else {
userInterestsBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public Builder setUserInterests(
int index, com.google.ads.googleads.v17.common.UserInterestInfo.Builder builderForValue) {
if (userInterestsBuilder_ == null) {
ensureUserInterestsIsMutable();
userInterests_.set(index, builderForValue.build());
onChanged();
} else {
userInterestsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public Builder addUserInterests(com.google.ads.googleads.v17.common.UserInterestInfo value) {
if (userInterestsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureUserInterestsIsMutable();
userInterests_.add(value);
onChanged();
} else {
userInterestsBuilder_.addMessage(value);
}
return this;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public Builder addUserInterests(
int index, com.google.ads.googleads.v17.common.UserInterestInfo value) {
if (userInterestsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureUserInterestsIsMutable();
userInterests_.add(index, value);
onChanged();
} else {
userInterestsBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public Builder addUserInterests(
com.google.ads.googleads.v17.common.UserInterestInfo.Builder builderForValue) {
if (userInterestsBuilder_ == null) {
ensureUserInterestsIsMutable();
userInterests_.add(builderForValue.build());
onChanged();
} else {
userInterestsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public Builder addUserInterests(
int index, com.google.ads.googleads.v17.common.UserInterestInfo.Builder builderForValue) {
if (userInterestsBuilder_ == null) {
ensureUserInterestsIsMutable();
userInterests_.add(index, builderForValue.build());
onChanged();
} else {
userInterestsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public Builder addAllUserInterests(
java.lang.Iterable extends com.google.ads.googleads.v17.common.UserInterestInfo> values) {
if (userInterestsBuilder_ == null) {
ensureUserInterestsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, userInterests_);
onChanged();
} else {
userInterestsBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public Builder clearUserInterests() {
if (userInterestsBuilder_ == null) {
userInterests_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000010);
onChanged();
} else {
userInterestsBuilder_.clear();
}
return this;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public Builder removeUserInterests(int index) {
if (userInterestsBuilder_ == null) {
ensureUserInterestsIsMutable();
userInterests_.remove(index);
onChanged();
} else {
userInterestsBuilder_.remove(index);
}
return this;
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public com.google.ads.googleads.v17.common.UserInterestInfo.Builder getUserInterestsBuilder(
int index) {
return getUserInterestsFieldBuilder().getBuilder(index);
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public com.google.ads.googleads.v17.common.UserInterestInfoOrBuilder getUserInterestsOrBuilder(
int index) {
if (userInterestsBuilder_ == null) {
return userInterests_.get(index); } else {
return userInterestsBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public java.util.List extends com.google.ads.googleads.v17.common.UserInterestInfoOrBuilder>
getUserInterestsOrBuilderList() {
if (userInterestsBuilder_ != null) {
return userInterestsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(userInterests_);
}
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public com.google.ads.googleads.v17.common.UserInterestInfo.Builder addUserInterestsBuilder() {
return getUserInterestsFieldBuilder().addBuilder(
com.google.ads.googleads.v17.common.UserInterestInfo.getDefaultInstance());
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public com.google.ads.googleads.v17.common.UserInterestInfo.Builder addUserInterestsBuilder(
int index) {
return getUserInterestsFieldBuilder().addBuilder(
index, com.google.ads.googleads.v17.common.UserInterestInfo.getDefaultInstance());
}
/**
*
* User interests defining this audience. Affinity and In-Market audiences
* are supported.
*
*
* repeated .google.ads.googleads.v17.common.UserInterestInfo user_interests = 5;
*/
public java.util.List
getUserInterestsBuilderList() {
return getUserInterestsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.UserInterestInfo, com.google.ads.googleads.v17.common.UserInterestInfo.Builder, com.google.ads.googleads.v17.common.UserInterestInfoOrBuilder>
getUserInterestsFieldBuilder() {
if (userInterestsBuilder_ == null) {
userInterestsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.common.UserInterestInfo, com.google.ads.googleads.v17.common.UserInterestInfo.Builder, com.google.ads.googleads.v17.common.UserInterestInfoOrBuilder>(
userInterests_,
((bitField0_ & 0x00000010) != 0),
getParentForChildren(),
isClean());
userInterests_ = null;
}
return userInterestsBuilder_;
}
private java.util.List topics_ =
java.util.Collections.emptyList();
private void ensureTopicsIsMutable() {
if (!((bitField0_ & 0x00000020) != 0)) {
topics_ = new java.util.ArrayList(topics_);
bitField0_ |= 0x00000020;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.services.AudienceInsightsTopic, com.google.ads.googleads.v17.services.AudienceInsightsTopic.Builder, com.google.ads.googleads.v17.services.AudienceInsightsTopicOrBuilder> topicsBuilder_;
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public java.util.List getTopicsList() {
if (topicsBuilder_ == null) {
return java.util.Collections.unmodifiableList(topics_);
} else {
return topicsBuilder_.getMessageList();
}
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public int getTopicsCount() {
if (topicsBuilder_ == null) {
return topics_.size();
} else {
return topicsBuilder_.getCount();
}
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public com.google.ads.googleads.v17.services.AudienceInsightsTopic getTopics(int index) {
if (topicsBuilder_ == null) {
return topics_.get(index);
} else {
return topicsBuilder_.getMessage(index);
}
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public Builder setTopics(
int index, com.google.ads.googleads.v17.services.AudienceInsightsTopic value) {
if (topicsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureTopicsIsMutable();
topics_.set(index, value);
onChanged();
} else {
topicsBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public Builder setTopics(
int index, com.google.ads.googleads.v17.services.AudienceInsightsTopic.Builder builderForValue) {
if (topicsBuilder_ == null) {
ensureTopicsIsMutable();
topics_.set(index, builderForValue.build());
onChanged();
} else {
topicsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public Builder addTopics(com.google.ads.googleads.v17.services.AudienceInsightsTopic value) {
if (topicsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureTopicsIsMutable();
topics_.add(value);
onChanged();
} else {
topicsBuilder_.addMessage(value);
}
return this;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public Builder addTopics(
int index, com.google.ads.googleads.v17.services.AudienceInsightsTopic value) {
if (topicsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureTopicsIsMutable();
topics_.add(index, value);
onChanged();
} else {
topicsBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public Builder addTopics(
com.google.ads.googleads.v17.services.AudienceInsightsTopic.Builder builderForValue) {
if (topicsBuilder_ == null) {
ensureTopicsIsMutable();
topics_.add(builderForValue.build());
onChanged();
} else {
topicsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public Builder addTopics(
int index, com.google.ads.googleads.v17.services.AudienceInsightsTopic.Builder builderForValue) {
if (topicsBuilder_ == null) {
ensureTopicsIsMutable();
topics_.add(index, builderForValue.build());
onChanged();
} else {
topicsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public Builder addAllTopics(
java.lang.Iterable extends com.google.ads.googleads.v17.services.AudienceInsightsTopic> values) {
if (topicsBuilder_ == null) {
ensureTopicsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, topics_);
onChanged();
} else {
topicsBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public Builder clearTopics() {
if (topicsBuilder_ == null) {
topics_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000020);
onChanged();
} else {
topicsBuilder_.clear();
}
return this;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public Builder removeTopics(int index) {
if (topicsBuilder_ == null) {
ensureTopicsIsMutable();
topics_.remove(index);
onChanged();
} else {
topicsBuilder_.remove(index);
}
return this;
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public com.google.ads.googleads.v17.services.AudienceInsightsTopic.Builder getTopicsBuilder(
int index) {
return getTopicsFieldBuilder().getBuilder(index);
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public com.google.ads.googleads.v17.services.AudienceInsightsTopicOrBuilder getTopicsOrBuilder(
int index) {
if (topicsBuilder_ == null) {
return topics_.get(index); } else {
return topicsBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public java.util.List extends com.google.ads.googleads.v17.services.AudienceInsightsTopicOrBuilder>
getTopicsOrBuilderList() {
if (topicsBuilder_ != null) {
return topicsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(topics_);
}
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public com.google.ads.googleads.v17.services.AudienceInsightsTopic.Builder addTopicsBuilder() {
return getTopicsFieldBuilder().addBuilder(
com.google.ads.googleads.v17.services.AudienceInsightsTopic.getDefaultInstance());
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public com.google.ads.googleads.v17.services.AudienceInsightsTopic.Builder addTopicsBuilder(
int index) {
return getTopicsFieldBuilder().addBuilder(
index, com.google.ads.googleads.v17.services.AudienceInsightsTopic.getDefaultInstance());
}
/**
*
* Topics, represented by Knowledge Graph entities and/or Product & Service
* categories, that this audience is interested in.
*
*
* repeated .google.ads.googleads.v17.services.AudienceInsightsTopic topics = 6;
*/
public java.util.List
getTopicsBuilderList() {
return getTopicsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.services.AudienceInsightsTopic, com.google.ads.googleads.v17.services.AudienceInsightsTopic.Builder, com.google.ads.googleads.v17.services.AudienceInsightsTopicOrBuilder>
getTopicsFieldBuilder() {
if (topicsBuilder_ == null) {
topicsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v17.services.AudienceInsightsTopic, com.google.ads.googleads.v17.services.AudienceInsightsTopic.Builder, com.google.ads.googleads.v17.services.AudienceInsightsTopicOrBuilder>(
topics_,
((bitField0_ & 0x00000020) != 0),
getParentForChildren(),
isClean());
topics_ = null;
}
return topicsBuilder_;
}
@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.v17.services.BasicInsightsAudience)
}
// @@protoc_insertion_point(class_scope:google.ads.googleads.v17.services.BasicInsightsAudience)
private static final com.google.ads.googleads.v17.services.BasicInsightsAudience DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.ads.googleads.v17.services.BasicInsightsAudience();
}
public static com.google.ads.googleads.v17.services.BasicInsightsAudience getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public BasicInsightsAudience 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.v17.services.BasicInsightsAudience getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy