All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.google.ads.googleads.v17.services.PlannableTargeting Maven / Gradle / Ivy

The newest version!
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/ads/googleads/v17/services/reach_plan_service.proto

// Protobuf Java Version: 3.25.3
package com.google.ads.googleads.v17.services;

/**
 * 
 * The targeting for which traffic metrics will be reported.
 * 
* * Protobuf type {@code google.ads.googleads.v17.services.PlannableTargeting} */ public final class PlannableTargeting extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.ads.googleads.v17.services.PlannableTargeting) PlannableTargetingOrBuilder { private static final long serialVersionUID = 0L; // Use PlannableTargeting.newBuilder() to construct. private PlannableTargeting(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private PlannableTargeting() { ageRanges_ = java.util.Collections.emptyList(); genders_ = java.util.Collections.emptyList(); devices_ = java.util.Collections.emptyList(); networks_ = java.util.Collections.emptyList(); youtubeSelectLineups_ = java.util.Collections.emptyList(); } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new PlannableTargeting(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.ads.googleads.v17.services.ReachPlanServiceProto.internal_static_google_ads_googleads_v17_services_PlannableTargeting_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.ads.googleads.v17.services.ReachPlanServiceProto.internal_static_google_ads_googleads_v17_services_PlannableTargeting_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.ads.googleads.v17.services.PlannableTargeting.class, com.google.ads.googleads.v17.services.PlannableTargeting.Builder.class); } private int bitField0_; public static final int AGE_RANGES_FIELD_NUMBER = 1; @SuppressWarnings("serial") private java.util.List ageRanges_; private static final com.google.protobuf.Internal.ListAdapter.Converter< java.lang.Integer, com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange> ageRanges_converter_ = new com.google.protobuf.Internal.ListAdapter.Converter< java.lang.Integer, com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange>() { public com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange convert(java.lang.Integer from) { com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange result = com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange.forNumber(from); return result == null ? com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange.UNRECOGNIZED : result; } }; /** *
   * Allowed plannable age ranges for the product for which metrics will be
   * reported. Actual targeting is computed by mapping this age range onto
   * standard Google common.AgeRangeInfo values.
   * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @return A list containing the ageRanges. */ @java.lang.Override public java.util.List getAgeRangesList() { return new com.google.protobuf.Internal.ListAdapter< java.lang.Integer, com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange>(ageRanges_, ageRanges_converter_); } /** *
   * Allowed plannable age ranges for the product for which metrics will be
   * reported. Actual targeting is computed by mapping this age range onto
   * standard Google common.AgeRangeInfo values.
   * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @return The count of ageRanges. */ @java.lang.Override public int getAgeRangesCount() { return ageRanges_.size(); } /** *
   * Allowed plannable age ranges for the product for which metrics will be
   * reported. Actual targeting is computed by mapping this age range onto
   * standard Google common.AgeRangeInfo values.
   * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @param index The index of the element to return. * @return The ageRanges at the given index. */ @java.lang.Override public com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange getAgeRanges(int index) { return ageRanges_converter_.convert(ageRanges_.get(index)); } /** *
   * Allowed plannable age ranges for the product for which metrics will be
   * reported. Actual targeting is computed by mapping this age range onto
   * standard Google common.AgeRangeInfo values.
   * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @return A list containing the enum numeric values on the wire for ageRanges. */ @java.lang.Override public java.util.List getAgeRangesValueList() { return ageRanges_; } /** *
   * Allowed plannable age ranges for the product for which metrics will be
   * reported. Actual targeting is computed by mapping this age range onto
   * standard Google common.AgeRangeInfo values.
   * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @param index The index of the value to return. * @return The enum numeric value on the wire of ageRanges at the given index. */ @java.lang.Override public int getAgeRangesValue(int index) { return ageRanges_.get(index); } private int ageRangesMemoizedSerializedSize; public static final int GENDERS_FIELD_NUMBER = 2; @SuppressWarnings("serial") private java.util.List genders_; /** *
   * Targetable genders for the ad product.
   * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ @java.lang.Override public java.util.List getGendersList() { return genders_; } /** *
   * Targetable genders for the ad product.
   * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ @java.lang.Override public java.util.List getGendersOrBuilderList() { return genders_; } /** *
   * Targetable genders for the ad product.
   * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ @java.lang.Override public int getGendersCount() { return genders_.size(); } /** *
   * Targetable genders for the ad product.
   * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ @java.lang.Override public com.google.ads.googleads.v17.common.GenderInfo getGenders(int index) { return genders_.get(index); } /** *
   * Targetable genders for the ad product.
   * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ @java.lang.Override public com.google.ads.googleads.v17.common.GenderInfoOrBuilder getGendersOrBuilder( int index) { return genders_.get(index); } public static final int DEVICES_FIELD_NUMBER = 3; @SuppressWarnings("serial") private java.util.List devices_; /** *
   * Targetable devices for the ad product.
   * TABLET device targeting is automatically applied to reported metrics
   * when MOBILE targeting is selected for CPM_MASTHEAD,
   * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
   * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ @java.lang.Override public java.util.List getDevicesList() { return devices_; } /** *
   * Targetable devices for the ad product.
   * TABLET device targeting is automatically applied to reported metrics
   * when MOBILE targeting is selected for CPM_MASTHEAD,
   * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
   * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ @java.lang.Override public java.util.List getDevicesOrBuilderList() { return devices_; } /** *
   * Targetable devices for the ad product.
   * TABLET device targeting is automatically applied to reported metrics
   * when MOBILE targeting is selected for CPM_MASTHEAD,
   * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
   * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ @java.lang.Override public int getDevicesCount() { return devices_.size(); } /** *
   * Targetable devices for the ad product.
   * TABLET device targeting is automatically applied to reported metrics
   * when MOBILE targeting is selected for CPM_MASTHEAD,
   * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
   * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ @java.lang.Override public com.google.ads.googleads.v17.common.DeviceInfo getDevices(int index) { return devices_.get(index); } /** *
   * Targetable devices for the ad product.
   * TABLET device targeting is automatically applied to reported metrics
   * when MOBILE targeting is selected for CPM_MASTHEAD,
   * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
   * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ @java.lang.Override public com.google.ads.googleads.v17.common.DeviceInfoOrBuilder getDevicesOrBuilder( int index) { return devices_.get(index); } public static final int NETWORKS_FIELD_NUMBER = 4; @SuppressWarnings("serial") private java.util.List networks_; private static final com.google.protobuf.Internal.ListAdapter.Converter< java.lang.Integer, com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork> networks_converter_ = new com.google.protobuf.Internal.ListAdapter.Converter< java.lang.Integer, com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork>() { public com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork convert(java.lang.Integer from) { com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork result = com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork.forNumber(from); return result == null ? com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork.UNRECOGNIZED : result; } }; /** *
   * Targetable networks for the ad product.
   * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @return A list containing the networks. */ @java.lang.Override public java.util.List getNetworksList() { return new com.google.protobuf.Internal.ListAdapter< java.lang.Integer, com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork>(networks_, networks_converter_); } /** *
   * Targetable networks for the ad product.
   * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @return The count of networks. */ @java.lang.Override public int getNetworksCount() { return networks_.size(); } /** *
   * Targetable networks for the ad product.
   * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @param index The index of the element to return. * @return The networks at the given index. */ @java.lang.Override public com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork getNetworks(int index) { return networks_converter_.convert(networks_.get(index)); } /** *
   * Targetable networks for the ad product.
   * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @return A list containing the enum numeric values on the wire for networks. */ @java.lang.Override public java.util.List getNetworksValueList() { return networks_; } /** *
   * Targetable networks for the ad product.
   * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @param index The index of the value to return. * @return The enum numeric value on the wire of networks at the given index. */ @java.lang.Override public int getNetworksValue(int index) { return networks_.get(index); } private int networksMemoizedSerializedSize; public static final int YOUTUBE_SELECT_LINEUPS_FIELD_NUMBER = 5; @SuppressWarnings("serial") private java.util.List youtubeSelectLineups_; /** *
   * Targetable YouTube Select Lineups for the ad product.
   * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ @java.lang.Override public java.util.List getYoutubeSelectLineupsList() { return youtubeSelectLineups_; } /** *
   * Targetable YouTube Select Lineups for the ad product.
   * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ @java.lang.Override public java.util.List getYoutubeSelectLineupsOrBuilderList() { return youtubeSelectLineups_; } /** *
   * Targetable YouTube Select Lineups for the ad product.
   * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ @java.lang.Override public int getYoutubeSelectLineupsCount() { return youtubeSelectLineups_.size(); } /** *
   * Targetable YouTube Select Lineups for the ad product.
   * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ @java.lang.Override public com.google.ads.googleads.v17.services.YouTubeSelectLineUp getYoutubeSelectLineups(int index) { return youtubeSelectLineups_.get(index); } /** *
   * Targetable YouTube Select Lineups for the ad product.
   * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ @java.lang.Override public com.google.ads.googleads.v17.services.YouTubeSelectLineUpOrBuilder getYoutubeSelectLineupsOrBuilder( int index) { return youtubeSelectLineups_.get(index); } public static final int SURFACE_TARGETING_FIELD_NUMBER = 6; private com.google.ads.googleads.v17.services.SurfaceTargetingCombinations surfaceTargeting_; /** *
   * Targetable surface combinations for the ad product.
   * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; * @return Whether the surfaceTargeting field is set. */ @java.lang.Override public boolean hasSurfaceTargeting() { return ((bitField0_ & 0x00000001) != 0); } /** *
   * Targetable surface combinations for the ad product.
   * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; * @return The surfaceTargeting. */ @java.lang.Override public com.google.ads.googleads.v17.services.SurfaceTargetingCombinations getSurfaceTargeting() { return surfaceTargeting_ == null ? com.google.ads.googleads.v17.services.SurfaceTargetingCombinations.getDefaultInstance() : surfaceTargeting_; } /** *
   * Targetable surface combinations for the ad product.
   * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; */ @java.lang.Override public com.google.ads.googleads.v17.services.SurfaceTargetingCombinationsOrBuilder getSurfaceTargetingOrBuilder() { return surfaceTargeting_ == null ? com.google.ads.googleads.v17.services.SurfaceTargetingCombinations.getDefaultInstance() : surfaceTargeting_; } 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 (getAgeRangesList().size() > 0) { output.writeUInt32NoTag(10); output.writeUInt32NoTag(ageRangesMemoizedSerializedSize); } for (int i = 0; i < ageRanges_.size(); i++) { output.writeEnumNoTag(ageRanges_.get(i)); } for (int i = 0; i < genders_.size(); i++) { output.writeMessage(2, genders_.get(i)); } for (int i = 0; i < devices_.size(); i++) { output.writeMessage(3, devices_.get(i)); } if (getNetworksList().size() > 0) { output.writeUInt32NoTag(34); output.writeUInt32NoTag(networksMemoizedSerializedSize); } for (int i = 0; i < networks_.size(); i++) { output.writeEnumNoTag(networks_.get(i)); } for (int i = 0; i < youtubeSelectLineups_.size(); i++) { output.writeMessage(5, youtubeSelectLineups_.get(i)); } if (((bitField0_ & 0x00000001) != 0)) { output.writeMessage(6, getSurfaceTargeting()); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; { int dataSize = 0; for (int i = 0; i < ageRanges_.size(); i++) { dataSize += com.google.protobuf.CodedOutputStream .computeEnumSizeNoTag(ageRanges_.get(i)); } size += dataSize; if (!getAgeRangesList().isEmpty()) { size += 1; size += com.google.protobuf.CodedOutputStream .computeUInt32SizeNoTag(dataSize); }ageRangesMemoizedSerializedSize = dataSize; } for (int i = 0; i < genders_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(2, genders_.get(i)); } for (int i = 0; i < devices_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(3, devices_.get(i)); } { int dataSize = 0; for (int i = 0; i < networks_.size(); i++) { dataSize += com.google.protobuf.CodedOutputStream .computeEnumSizeNoTag(networks_.get(i)); } size += dataSize; if (!getNetworksList().isEmpty()) { size += 1; size += com.google.protobuf.CodedOutputStream .computeUInt32SizeNoTag(dataSize); }networksMemoizedSerializedSize = dataSize; } for (int i = 0; i < youtubeSelectLineups_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(5, youtubeSelectLineups_.get(i)); } if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(6, getSurfaceTargeting()); } 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.PlannableTargeting)) { return super.equals(obj); } com.google.ads.googleads.v17.services.PlannableTargeting other = (com.google.ads.googleads.v17.services.PlannableTargeting) obj; if (!ageRanges_.equals(other.ageRanges_)) return false; if (!getGendersList() .equals(other.getGendersList())) return false; if (!getDevicesList() .equals(other.getDevicesList())) return false; if (!networks_.equals(other.networks_)) return false; if (!getYoutubeSelectLineupsList() .equals(other.getYoutubeSelectLineupsList())) return false; if (hasSurfaceTargeting() != other.hasSurfaceTargeting()) return false; if (hasSurfaceTargeting()) { if (!getSurfaceTargeting() .equals(other.getSurfaceTargeting())) 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 (getAgeRangesCount() > 0) { hash = (37 * hash) + AGE_RANGES_FIELD_NUMBER; hash = (53 * hash) + ageRanges_.hashCode(); } if (getGendersCount() > 0) { hash = (37 * hash) + GENDERS_FIELD_NUMBER; hash = (53 * hash) + getGendersList().hashCode(); } if (getDevicesCount() > 0) { hash = (37 * hash) + DEVICES_FIELD_NUMBER; hash = (53 * hash) + getDevicesList().hashCode(); } if (getNetworksCount() > 0) { hash = (37 * hash) + NETWORKS_FIELD_NUMBER; hash = (53 * hash) + networks_.hashCode(); } if (getYoutubeSelectLineupsCount() > 0) { hash = (37 * hash) + YOUTUBE_SELECT_LINEUPS_FIELD_NUMBER; hash = (53 * hash) + getYoutubeSelectLineupsList().hashCode(); } if (hasSurfaceTargeting()) { hash = (37 * hash) + SURFACE_TARGETING_FIELD_NUMBER; hash = (53 * hash) + getSurfaceTargeting().hashCode(); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.ads.googleads.v17.services.PlannableTargeting parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.ads.googleads.v17.services.PlannableTargeting 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.PlannableTargeting parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.ads.googleads.v17.services.PlannableTargeting 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.PlannableTargeting parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.ads.googleads.v17.services.PlannableTargeting 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.PlannableTargeting 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.PlannableTargeting 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.PlannableTargeting 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.PlannableTargeting 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.PlannableTargeting 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.PlannableTargeting 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.PlannableTargeting 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; } /** *
   * The targeting for which traffic metrics will be reported.
   * 
* * Protobuf type {@code google.ads.googleads.v17.services.PlannableTargeting} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.ads.googleads.v17.services.PlannableTargeting) com.google.ads.googleads.v17.services.PlannableTargetingOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.ads.googleads.v17.services.ReachPlanServiceProto.internal_static_google_ads_googleads_v17_services_PlannableTargeting_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.ads.googleads.v17.services.ReachPlanServiceProto.internal_static_google_ads_googleads_v17_services_PlannableTargeting_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.ads.googleads.v17.services.PlannableTargeting.class, com.google.ads.googleads.v17.services.PlannableTargeting.Builder.class); } // Construct using com.google.ads.googleads.v17.services.PlannableTargeting.newBuilder() private Builder() { maybeForceBuilderInitialization(); } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } private void maybeForceBuilderInitialization() { if (com.google.protobuf.GeneratedMessageV3 .alwaysUseFieldBuilders) { getGendersFieldBuilder(); getDevicesFieldBuilder(); getYoutubeSelectLineupsFieldBuilder(); getSurfaceTargetingFieldBuilder(); } } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; ageRanges_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); if (gendersBuilder_ == null) { genders_ = java.util.Collections.emptyList(); } else { genders_ = null; gendersBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000002); if (devicesBuilder_ == null) { devices_ = java.util.Collections.emptyList(); } else { devices_ = null; devicesBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000004); networks_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000008); if (youtubeSelectLineupsBuilder_ == null) { youtubeSelectLineups_ = java.util.Collections.emptyList(); } else { youtubeSelectLineups_ = null; youtubeSelectLineupsBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000010); surfaceTargeting_ = null; if (surfaceTargetingBuilder_ != null) { surfaceTargetingBuilder_.dispose(); surfaceTargetingBuilder_ = null; } return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.ads.googleads.v17.services.ReachPlanServiceProto.internal_static_google_ads_googleads_v17_services_PlannableTargeting_descriptor; } @java.lang.Override public com.google.ads.googleads.v17.services.PlannableTargeting getDefaultInstanceForType() { return com.google.ads.googleads.v17.services.PlannableTargeting.getDefaultInstance(); } @java.lang.Override public com.google.ads.googleads.v17.services.PlannableTargeting build() { com.google.ads.googleads.v17.services.PlannableTargeting result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.ads.googleads.v17.services.PlannableTargeting buildPartial() { com.google.ads.googleads.v17.services.PlannableTargeting result = new com.google.ads.googleads.v17.services.PlannableTargeting(this); buildPartialRepeatedFields(result); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartialRepeatedFields(com.google.ads.googleads.v17.services.PlannableTargeting result) { if (((bitField0_ & 0x00000001) != 0)) { ageRanges_ = java.util.Collections.unmodifiableList(ageRanges_); bitField0_ = (bitField0_ & ~0x00000001); } result.ageRanges_ = ageRanges_; if (gendersBuilder_ == null) { if (((bitField0_ & 0x00000002) != 0)) { genders_ = java.util.Collections.unmodifiableList(genders_); bitField0_ = (bitField0_ & ~0x00000002); } result.genders_ = genders_; } else { result.genders_ = gendersBuilder_.build(); } if (devicesBuilder_ == null) { if (((bitField0_ & 0x00000004) != 0)) { devices_ = java.util.Collections.unmodifiableList(devices_); bitField0_ = (bitField0_ & ~0x00000004); } result.devices_ = devices_; } else { result.devices_ = devicesBuilder_.build(); } if (((bitField0_ & 0x00000008) != 0)) { networks_ = java.util.Collections.unmodifiableList(networks_); bitField0_ = (bitField0_ & ~0x00000008); } result.networks_ = networks_; if (youtubeSelectLineupsBuilder_ == null) { if (((bitField0_ & 0x00000010) != 0)) { youtubeSelectLineups_ = java.util.Collections.unmodifiableList(youtubeSelectLineups_); bitField0_ = (bitField0_ & ~0x00000010); } result.youtubeSelectLineups_ = youtubeSelectLineups_; } else { result.youtubeSelectLineups_ = youtubeSelectLineupsBuilder_.build(); } } private void buildPartial0(com.google.ads.googleads.v17.services.PlannableTargeting result) { int from_bitField0_ = bitField0_; int to_bitField0_ = 0; if (((from_bitField0_ & 0x00000020) != 0)) { result.surfaceTargeting_ = surfaceTargetingBuilder_ == null ? surfaceTargeting_ : surfaceTargetingBuilder_.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.PlannableTargeting) { return mergeFrom((com.google.ads.googleads.v17.services.PlannableTargeting)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.ads.googleads.v17.services.PlannableTargeting other) { if (other == com.google.ads.googleads.v17.services.PlannableTargeting.getDefaultInstance()) return this; if (!other.ageRanges_.isEmpty()) { if (ageRanges_.isEmpty()) { ageRanges_ = other.ageRanges_; bitField0_ = (bitField0_ & ~0x00000001); } else { ensureAgeRangesIsMutable(); ageRanges_.addAll(other.ageRanges_); } onChanged(); } if (gendersBuilder_ == null) { if (!other.genders_.isEmpty()) { if (genders_.isEmpty()) { genders_ = other.genders_; bitField0_ = (bitField0_ & ~0x00000002); } else { ensureGendersIsMutable(); genders_.addAll(other.genders_); } onChanged(); } } else { if (!other.genders_.isEmpty()) { if (gendersBuilder_.isEmpty()) { gendersBuilder_.dispose(); gendersBuilder_ = null; genders_ = other.genders_; bitField0_ = (bitField0_ & ~0x00000002); gendersBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getGendersFieldBuilder() : null; } else { gendersBuilder_.addAllMessages(other.genders_); } } } if (devicesBuilder_ == null) { if (!other.devices_.isEmpty()) { if (devices_.isEmpty()) { devices_ = other.devices_; bitField0_ = (bitField0_ & ~0x00000004); } else { ensureDevicesIsMutable(); devices_.addAll(other.devices_); } onChanged(); } } else { if (!other.devices_.isEmpty()) { if (devicesBuilder_.isEmpty()) { devicesBuilder_.dispose(); devicesBuilder_ = null; devices_ = other.devices_; bitField0_ = (bitField0_ & ~0x00000004); devicesBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getDevicesFieldBuilder() : null; } else { devicesBuilder_.addAllMessages(other.devices_); } } } if (!other.networks_.isEmpty()) { if (networks_.isEmpty()) { networks_ = other.networks_; bitField0_ = (bitField0_ & ~0x00000008); } else { ensureNetworksIsMutable(); networks_.addAll(other.networks_); } onChanged(); } if (youtubeSelectLineupsBuilder_ == null) { if (!other.youtubeSelectLineups_.isEmpty()) { if (youtubeSelectLineups_.isEmpty()) { youtubeSelectLineups_ = other.youtubeSelectLineups_; bitField0_ = (bitField0_ & ~0x00000010); } else { ensureYoutubeSelectLineupsIsMutable(); youtubeSelectLineups_.addAll(other.youtubeSelectLineups_); } onChanged(); } } else { if (!other.youtubeSelectLineups_.isEmpty()) { if (youtubeSelectLineupsBuilder_.isEmpty()) { youtubeSelectLineupsBuilder_.dispose(); youtubeSelectLineupsBuilder_ = null; youtubeSelectLineups_ = other.youtubeSelectLineups_; bitField0_ = (bitField0_ & ~0x00000010); youtubeSelectLineupsBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getYoutubeSelectLineupsFieldBuilder() : null; } else { youtubeSelectLineupsBuilder_.addAllMessages(other.youtubeSelectLineups_); } } } if (other.hasSurfaceTargeting()) { mergeSurfaceTargeting(other.getSurfaceTargeting()); } 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: { int tmpRaw = input.readEnum(); ensureAgeRangesIsMutable(); ageRanges_.add(tmpRaw); break; } // case 8 case 10: { int length = input.readRawVarint32(); int oldLimit = input.pushLimit(length); while(input.getBytesUntilLimit() > 0) { int tmpRaw = input.readEnum(); ensureAgeRangesIsMutable(); ageRanges_.add(tmpRaw); } input.popLimit(oldLimit); break; } // case 10 case 18: { com.google.ads.googleads.v17.common.GenderInfo m = input.readMessage( com.google.ads.googleads.v17.common.GenderInfo.parser(), extensionRegistry); if (gendersBuilder_ == null) { ensureGendersIsMutable(); genders_.add(m); } else { gendersBuilder_.addMessage(m); } break; } // case 18 case 26: { com.google.ads.googleads.v17.common.DeviceInfo m = input.readMessage( com.google.ads.googleads.v17.common.DeviceInfo.parser(), extensionRegistry); if (devicesBuilder_ == null) { ensureDevicesIsMutable(); devices_.add(m); } else { devicesBuilder_.addMessage(m); } break; } // case 26 case 32: { int tmpRaw = input.readEnum(); ensureNetworksIsMutable(); networks_.add(tmpRaw); break; } // case 32 case 34: { int length = input.readRawVarint32(); int oldLimit = input.pushLimit(length); while(input.getBytesUntilLimit() > 0) { int tmpRaw = input.readEnum(); ensureNetworksIsMutable(); networks_.add(tmpRaw); } input.popLimit(oldLimit); break; } // case 34 case 42: { com.google.ads.googleads.v17.services.YouTubeSelectLineUp m = input.readMessage( com.google.ads.googleads.v17.services.YouTubeSelectLineUp.parser(), extensionRegistry); if (youtubeSelectLineupsBuilder_ == null) { ensureYoutubeSelectLineupsIsMutable(); youtubeSelectLineups_.add(m); } else { youtubeSelectLineupsBuilder_.addMessage(m); } break; } // case 42 case 50: { input.readMessage( getSurfaceTargetingFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000020; 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 ageRanges_ = java.util.Collections.emptyList(); private void ensureAgeRangesIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { ageRanges_ = new java.util.ArrayList(ageRanges_); bitField0_ |= 0x00000001; } } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @return A list containing the ageRanges. */ public java.util.List getAgeRangesList() { return new com.google.protobuf.Internal.ListAdapter< java.lang.Integer, com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange>(ageRanges_, ageRanges_converter_); } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @return The count of ageRanges. */ public int getAgeRangesCount() { return ageRanges_.size(); } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @param index The index of the element to return. * @return The ageRanges at the given index. */ public com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange getAgeRanges(int index) { return ageRanges_converter_.convert(ageRanges_.get(index)); } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @param index The index to set the value at. * @param value The ageRanges to set. * @return This builder for chaining. */ public Builder setAgeRanges( int index, com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange value) { if (value == null) { throw new NullPointerException(); } ensureAgeRangesIsMutable(); ageRanges_.set(index, value.getNumber()); onChanged(); return this; } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @param value The ageRanges to add. * @return This builder for chaining. */ public Builder addAgeRanges(com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange value) { if (value == null) { throw new NullPointerException(); } ensureAgeRangesIsMutable(); ageRanges_.add(value.getNumber()); onChanged(); return this; } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @param values The ageRanges to add. * @return This builder for chaining. */ public Builder addAllAgeRanges( java.lang.Iterable values) { ensureAgeRangesIsMutable(); for (com.google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange value : values) { ageRanges_.add(value.getNumber()); } onChanged(); return this; } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @return This builder for chaining. */ public Builder clearAgeRanges() { ageRanges_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @return A list containing the enum numeric values on the wire for ageRanges. */ public java.util.List getAgeRangesValueList() { return java.util.Collections.unmodifiableList(ageRanges_); } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @param index The index of the value to return. * @return The enum numeric value on the wire of ageRanges at the given index. */ public int getAgeRangesValue(int index) { return ageRanges_.get(index); } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @param index The index to set the value at. * @param value The enum numeric value on the wire for ageRanges to set. * @return This builder for chaining. */ public Builder setAgeRangesValue( int index, int value) { ensureAgeRangesIsMutable(); ageRanges_.set(index, value); onChanged(); return this; } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @param value The enum numeric value on the wire for ageRanges to add. * @return This builder for chaining. */ public Builder addAgeRangesValue(int value) { ensureAgeRangesIsMutable(); ageRanges_.add(value); onChanged(); return this; } /** *
     * Allowed plannable age ranges for the product for which metrics will be
     * reported. Actual targeting is computed by mapping this age range onto
     * standard Google common.AgeRangeInfo values.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanAgeRangeEnum.ReachPlanAgeRange age_ranges = 1; * @param values The enum numeric values on the wire for ageRanges to add. * @return This builder for chaining. */ public Builder addAllAgeRangesValue( java.lang.Iterable values) { ensureAgeRangesIsMutable(); for (int value : values) { ageRanges_.add(value); } onChanged(); return this; } private java.util.List genders_ = java.util.Collections.emptyList(); private void ensureGendersIsMutable() { if (!((bitField0_ & 0x00000002) != 0)) { genders_ = new java.util.ArrayList(genders_); bitField0_ |= 0x00000002; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.ads.googleads.v17.common.GenderInfo, com.google.ads.googleads.v17.common.GenderInfo.Builder, com.google.ads.googleads.v17.common.GenderInfoOrBuilder> gendersBuilder_; /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public java.util.List getGendersList() { if (gendersBuilder_ == null) { return java.util.Collections.unmodifiableList(genders_); } else { return gendersBuilder_.getMessageList(); } } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public int getGendersCount() { if (gendersBuilder_ == null) { return genders_.size(); } else { return gendersBuilder_.getCount(); } } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public com.google.ads.googleads.v17.common.GenderInfo getGenders(int index) { if (gendersBuilder_ == null) { return genders_.get(index); } else { return gendersBuilder_.getMessage(index); } } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public Builder setGenders( int index, com.google.ads.googleads.v17.common.GenderInfo value) { if (gendersBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureGendersIsMutable(); genders_.set(index, value); onChanged(); } else { gendersBuilder_.setMessage(index, value); } return this; } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public Builder setGenders( int index, com.google.ads.googleads.v17.common.GenderInfo.Builder builderForValue) { if (gendersBuilder_ == null) { ensureGendersIsMutable(); genders_.set(index, builderForValue.build()); onChanged(); } else { gendersBuilder_.setMessage(index, builderForValue.build()); } return this; } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public Builder addGenders(com.google.ads.googleads.v17.common.GenderInfo value) { if (gendersBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureGendersIsMutable(); genders_.add(value); onChanged(); } else { gendersBuilder_.addMessage(value); } return this; } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public Builder addGenders( int index, com.google.ads.googleads.v17.common.GenderInfo value) { if (gendersBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureGendersIsMutable(); genders_.add(index, value); onChanged(); } else { gendersBuilder_.addMessage(index, value); } return this; } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public Builder addGenders( com.google.ads.googleads.v17.common.GenderInfo.Builder builderForValue) { if (gendersBuilder_ == null) { ensureGendersIsMutable(); genders_.add(builderForValue.build()); onChanged(); } else { gendersBuilder_.addMessage(builderForValue.build()); } return this; } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public Builder addGenders( int index, com.google.ads.googleads.v17.common.GenderInfo.Builder builderForValue) { if (gendersBuilder_ == null) { ensureGendersIsMutable(); genders_.add(index, builderForValue.build()); onChanged(); } else { gendersBuilder_.addMessage(index, builderForValue.build()); } return this; } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public Builder addAllGenders( java.lang.Iterable values) { if (gendersBuilder_ == null) { ensureGendersIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, genders_); onChanged(); } else { gendersBuilder_.addAllMessages(values); } return this; } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public Builder clearGenders() { if (gendersBuilder_ == null) { genders_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); } else { gendersBuilder_.clear(); } return this; } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public Builder removeGenders(int index) { if (gendersBuilder_ == null) { ensureGendersIsMutable(); genders_.remove(index); onChanged(); } else { gendersBuilder_.remove(index); } return this; } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public com.google.ads.googleads.v17.common.GenderInfo.Builder getGendersBuilder( int index) { return getGendersFieldBuilder().getBuilder(index); } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public com.google.ads.googleads.v17.common.GenderInfoOrBuilder getGendersOrBuilder( int index) { if (gendersBuilder_ == null) { return genders_.get(index); } else { return gendersBuilder_.getMessageOrBuilder(index); } } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public java.util.List getGendersOrBuilderList() { if (gendersBuilder_ != null) { return gendersBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(genders_); } } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public com.google.ads.googleads.v17.common.GenderInfo.Builder addGendersBuilder() { return getGendersFieldBuilder().addBuilder( com.google.ads.googleads.v17.common.GenderInfo.getDefaultInstance()); } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public com.google.ads.googleads.v17.common.GenderInfo.Builder addGendersBuilder( int index) { return getGendersFieldBuilder().addBuilder( index, com.google.ads.googleads.v17.common.GenderInfo.getDefaultInstance()); } /** *
     * Targetable genders for the ad product.
     * 
* * repeated .google.ads.googleads.v17.common.GenderInfo genders = 2; */ public java.util.List getGendersBuilderList() { return getGendersFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.ads.googleads.v17.common.GenderInfo, com.google.ads.googleads.v17.common.GenderInfo.Builder, com.google.ads.googleads.v17.common.GenderInfoOrBuilder> getGendersFieldBuilder() { if (gendersBuilder_ == null) { gendersBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.ads.googleads.v17.common.GenderInfo, com.google.ads.googleads.v17.common.GenderInfo.Builder, com.google.ads.googleads.v17.common.GenderInfoOrBuilder>( genders_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); genders_ = null; } return gendersBuilder_; } private java.util.List devices_ = java.util.Collections.emptyList(); private void ensureDevicesIsMutable() { if (!((bitField0_ & 0x00000004) != 0)) { devices_ = new java.util.ArrayList(devices_); bitField0_ |= 0x00000004; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.ads.googleads.v17.common.DeviceInfo, com.google.ads.googleads.v17.common.DeviceInfo.Builder, com.google.ads.googleads.v17.common.DeviceInfoOrBuilder> devicesBuilder_; /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public java.util.List getDevicesList() { if (devicesBuilder_ == null) { return java.util.Collections.unmodifiableList(devices_); } else { return devicesBuilder_.getMessageList(); } } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public int getDevicesCount() { if (devicesBuilder_ == null) { return devices_.size(); } else { return devicesBuilder_.getCount(); } } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public com.google.ads.googleads.v17.common.DeviceInfo getDevices(int index) { if (devicesBuilder_ == null) { return devices_.get(index); } else { return devicesBuilder_.getMessage(index); } } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public Builder setDevices( int index, com.google.ads.googleads.v17.common.DeviceInfo value) { if (devicesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureDevicesIsMutable(); devices_.set(index, value); onChanged(); } else { devicesBuilder_.setMessage(index, value); } return this; } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public Builder setDevices( int index, com.google.ads.googleads.v17.common.DeviceInfo.Builder builderForValue) { if (devicesBuilder_ == null) { ensureDevicesIsMutable(); devices_.set(index, builderForValue.build()); onChanged(); } else { devicesBuilder_.setMessage(index, builderForValue.build()); } return this; } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public Builder addDevices(com.google.ads.googleads.v17.common.DeviceInfo value) { if (devicesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureDevicesIsMutable(); devices_.add(value); onChanged(); } else { devicesBuilder_.addMessage(value); } return this; } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public Builder addDevices( int index, com.google.ads.googleads.v17.common.DeviceInfo value) { if (devicesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureDevicesIsMutable(); devices_.add(index, value); onChanged(); } else { devicesBuilder_.addMessage(index, value); } return this; } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public Builder addDevices( com.google.ads.googleads.v17.common.DeviceInfo.Builder builderForValue) { if (devicesBuilder_ == null) { ensureDevicesIsMutable(); devices_.add(builderForValue.build()); onChanged(); } else { devicesBuilder_.addMessage(builderForValue.build()); } return this; } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public Builder addDevices( int index, com.google.ads.googleads.v17.common.DeviceInfo.Builder builderForValue) { if (devicesBuilder_ == null) { ensureDevicesIsMutable(); devices_.add(index, builderForValue.build()); onChanged(); } else { devicesBuilder_.addMessage(index, builderForValue.build()); } return this; } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public Builder addAllDevices( java.lang.Iterable values) { if (devicesBuilder_ == null) { ensureDevicesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, devices_); onChanged(); } else { devicesBuilder_.addAllMessages(values); } return this; } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public Builder clearDevices() { if (devicesBuilder_ == null) { devices_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000004); onChanged(); } else { devicesBuilder_.clear(); } return this; } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public Builder removeDevices(int index) { if (devicesBuilder_ == null) { ensureDevicesIsMutable(); devices_.remove(index); onChanged(); } else { devicesBuilder_.remove(index); } return this; } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public com.google.ads.googleads.v17.common.DeviceInfo.Builder getDevicesBuilder( int index) { return getDevicesFieldBuilder().getBuilder(index); } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public com.google.ads.googleads.v17.common.DeviceInfoOrBuilder getDevicesOrBuilder( int index) { if (devicesBuilder_ == null) { return devices_.get(index); } else { return devicesBuilder_.getMessageOrBuilder(index); } } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public java.util.List getDevicesOrBuilderList() { if (devicesBuilder_ != null) { return devicesBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(devices_); } } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public com.google.ads.googleads.v17.common.DeviceInfo.Builder addDevicesBuilder() { return getDevicesFieldBuilder().addBuilder( com.google.ads.googleads.v17.common.DeviceInfo.getDefaultInstance()); } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public com.google.ads.googleads.v17.common.DeviceInfo.Builder addDevicesBuilder( int index) { return getDevicesFieldBuilder().addBuilder( index, com.google.ads.googleads.v17.common.DeviceInfo.getDefaultInstance()); } /** *
     * Targetable devices for the ad product.
     * TABLET device targeting is automatically applied to reported metrics
     * when MOBILE targeting is selected for CPM_MASTHEAD,
     * GOOGLE_PREFERRED_BUMPER, and GOOGLE_PREFERRED_SHORT products.
     * 
* * repeated .google.ads.googleads.v17.common.DeviceInfo devices = 3; */ public java.util.List getDevicesBuilderList() { return getDevicesFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.ads.googleads.v17.common.DeviceInfo, com.google.ads.googleads.v17.common.DeviceInfo.Builder, com.google.ads.googleads.v17.common.DeviceInfoOrBuilder> getDevicesFieldBuilder() { if (devicesBuilder_ == null) { devicesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.ads.googleads.v17.common.DeviceInfo, com.google.ads.googleads.v17.common.DeviceInfo.Builder, com.google.ads.googleads.v17.common.DeviceInfoOrBuilder>( devices_, ((bitField0_ & 0x00000004) != 0), getParentForChildren(), isClean()); devices_ = null; } return devicesBuilder_; } private java.util.List networks_ = java.util.Collections.emptyList(); private void ensureNetworksIsMutable() { if (!((bitField0_ & 0x00000008) != 0)) { networks_ = new java.util.ArrayList(networks_); bitField0_ |= 0x00000008; } } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @return A list containing the networks. */ public java.util.List getNetworksList() { return new com.google.protobuf.Internal.ListAdapter< java.lang.Integer, com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork>(networks_, networks_converter_); } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @return The count of networks. */ public int getNetworksCount() { return networks_.size(); } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @param index The index of the element to return. * @return The networks at the given index. */ public com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork getNetworks(int index) { return networks_converter_.convert(networks_.get(index)); } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @param index The index to set the value at. * @param value The networks to set. * @return This builder for chaining. */ public Builder setNetworks( int index, com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork value) { if (value == null) { throw new NullPointerException(); } ensureNetworksIsMutable(); networks_.set(index, value.getNumber()); onChanged(); return this; } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @param value The networks to add. * @return This builder for chaining. */ public Builder addNetworks(com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork value) { if (value == null) { throw new NullPointerException(); } ensureNetworksIsMutable(); networks_.add(value.getNumber()); onChanged(); return this; } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @param values The networks to add. * @return This builder for chaining. */ public Builder addAllNetworks( java.lang.Iterable values) { ensureNetworksIsMutable(); for (com.google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork value : values) { networks_.add(value.getNumber()); } onChanged(); return this; } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @return This builder for chaining. */ public Builder clearNetworks() { networks_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000008); onChanged(); return this; } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @return A list containing the enum numeric values on the wire for networks. */ public java.util.List getNetworksValueList() { return java.util.Collections.unmodifiableList(networks_); } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @param index The index of the value to return. * @return The enum numeric value on the wire of networks at the given index. */ public int getNetworksValue(int index) { return networks_.get(index); } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @param index The index to set the value at. * @param value The enum numeric value on the wire for networks to set. * @return This builder for chaining. */ public Builder setNetworksValue( int index, int value) { ensureNetworksIsMutable(); networks_.set(index, value); onChanged(); return this; } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @param value The enum numeric value on the wire for networks to add. * @return This builder for chaining. */ public Builder addNetworksValue(int value) { ensureNetworksIsMutable(); networks_.add(value); onChanged(); return this; } /** *
     * Targetable networks for the ad product.
     * 
* * repeated .google.ads.googleads.v17.enums.ReachPlanNetworkEnum.ReachPlanNetwork networks = 4; * @param values The enum numeric values on the wire for networks to add. * @return This builder for chaining. */ public Builder addAllNetworksValue( java.lang.Iterable values) { ensureNetworksIsMutable(); for (int value : values) { networks_.add(value); } onChanged(); return this; } private java.util.List youtubeSelectLineups_ = java.util.Collections.emptyList(); private void ensureYoutubeSelectLineupsIsMutable() { if (!((bitField0_ & 0x00000010) != 0)) { youtubeSelectLineups_ = new java.util.ArrayList(youtubeSelectLineups_); bitField0_ |= 0x00000010; } } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.ads.googleads.v17.services.YouTubeSelectLineUp, com.google.ads.googleads.v17.services.YouTubeSelectLineUp.Builder, com.google.ads.googleads.v17.services.YouTubeSelectLineUpOrBuilder> youtubeSelectLineupsBuilder_; /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public java.util.List getYoutubeSelectLineupsList() { if (youtubeSelectLineupsBuilder_ == null) { return java.util.Collections.unmodifiableList(youtubeSelectLineups_); } else { return youtubeSelectLineupsBuilder_.getMessageList(); } } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public int getYoutubeSelectLineupsCount() { if (youtubeSelectLineupsBuilder_ == null) { return youtubeSelectLineups_.size(); } else { return youtubeSelectLineupsBuilder_.getCount(); } } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public com.google.ads.googleads.v17.services.YouTubeSelectLineUp getYoutubeSelectLineups(int index) { if (youtubeSelectLineupsBuilder_ == null) { return youtubeSelectLineups_.get(index); } else { return youtubeSelectLineupsBuilder_.getMessage(index); } } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public Builder setYoutubeSelectLineups( int index, com.google.ads.googleads.v17.services.YouTubeSelectLineUp value) { if (youtubeSelectLineupsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureYoutubeSelectLineupsIsMutable(); youtubeSelectLineups_.set(index, value); onChanged(); } else { youtubeSelectLineupsBuilder_.setMessage(index, value); } return this; } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public Builder setYoutubeSelectLineups( int index, com.google.ads.googleads.v17.services.YouTubeSelectLineUp.Builder builderForValue) { if (youtubeSelectLineupsBuilder_ == null) { ensureYoutubeSelectLineupsIsMutable(); youtubeSelectLineups_.set(index, builderForValue.build()); onChanged(); } else { youtubeSelectLineupsBuilder_.setMessage(index, builderForValue.build()); } return this; } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public Builder addYoutubeSelectLineups(com.google.ads.googleads.v17.services.YouTubeSelectLineUp value) { if (youtubeSelectLineupsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureYoutubeSelectLineupsIsMutable(); youtubeSelectLineups_.add(value); onChanged(); } else { youtubeSelectLineupsBuilder_.addMessage(value); } return this; } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public Builder addYoutubeSelectLineups( int index, com.google.ads.googleads.v17.services.YouTubeSelectLineUp value) { if (youtubeSelectLineupsBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureYoutubeSelectLineupsIsMutable(); youtubeSelectLineups_.add(index, value); onChanged(); } else { youtubeSelectLineupsBuilder_.addMessage(index, value); } return this; } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public Builder addYoutubeSelectLineups( com.google.ads.googleads.v17.services.YouTubeSelectLineUp.Builder builderForValue) { if (youtubeSelectLineupsBuilder_ == null) { ensureYoutubeSelectLineupsIsMutable(); youtubeSelectLineups_.add(builderForValue.build()); onChanged(); } else { youtubeSelectLineupsBuilder_.addMessage(builderForValue.build()); } return this; } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public Builder addYoutubeSelectLineups( int index, com.google.ads.googleads.v17.services.YouTubeSelectLineUp.Builder builderForValue) { if (youtubeSelectLineupsBuilder_ == null) { ensureYoutubeSelectLineupsIsMutable(); youtubeSelectLineups_.add(index, builderForValue.build()); onChanged(); } else { youtubeSelectLineupsBuilder_.addMessage(index, builderForValue.build()); } return this; } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public Builder addAllYoutubeSelectLineups( java.lang.Iterable values) { if (youtubeSelectLineupsBuilder_ == null) { ensureYoutubeSelectLineupsIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, youtubeSelectLineups_); onChanged(); } else { youtubeSelectLineupsBuilder_.addAllMessages(values); } return this; } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public Builder clearYoutubeSelectLineups() { if (youtubeSelectLineupsBuilder_ == null) { youtubeSelectLineups_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00000010); onChanged(); } else { youtubeSelectLineupsBuilder_.clear(); } return this; } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public Builder removeYoutubeSelectLineups(int index) { if (youtubeSelectLineupsBuilder_ == null) { ensureYoutubeSelectLineupsIsMutable(); youtubeSelectLineups_.remove(index); onChanged(); } else { youtubeSelectLineupsBuilder_.remove(index); } return this; } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public com.google.ads.googleads.v17.services.YouTubeSelectLineUp.Builder getYoutubeSelectLineupsBuilder( int index) { return getYoutubeSelectLineupsFieldBuilder().getBuilder(index); } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public com.google.ads.googleads.v17.services.YouTubeSelectLineUpOrBuilder getYoutubeSelectLineupsOrBuilder( int index) { if (youtubeSelectLineupsBuilder_ == null) { return youtubeSelectLineups_.get(index); } else { return youtubeSelectLineupsBuilder_.getMessageOrBuilder(index); } } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public java.util.List getYoutubeSelectLineupsOrBuilderList() { if (youtubeSelectLineupsBuilder_ != null) { return youtubeSelectLineupsBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(youtubeSelectLineups_); } } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public com.google.ads.googleads.v17.services.YouTubeSelectLineUp.Builder addYoutubeSelectLineupsBuilder() { return getYoutubeSelectLineupsFieldBuilder().addBuilder( com.google.ads.googleads.v17.services.YouTubeSelectLineUp.getDefaultInstance()); } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public com.google.ads.googleads.v17.services.YouTubeSelectLineUp.Builder addYoutubeSelectLineupsBuilder( int index) { return getYoutubeSelectLineupsFieldBuilder().addBuilder( index, com.google.ads.googleads.v17.services.YouTubeSelectLineUp.getDefaultInstance()); } /** *
     * Targetable YouTube Select Lineups for the ad product.
     * 
* * repeated .google.ads.googleads.v17.services.YouTubeSelectLineUp youtube_select_lineups = 5; */ public java.util.List getYoutubeSelectLineupsBuilderList() { return getYoutubeSelectLineupsFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< com.google.ads.googleads.v17.services.YouTubeSelectLineUp, com.google.ads.googleads.v17.services.YouTubeSelectLineUp.Builder, com.google.ads.googleads.v17.services.YouTubeSelectLineUpOrBuilder> getYoutubeSelectLineupsFieldBuilder() { if (youtubeSelectLineupsBuilder_ == null) { youtubeSelectLineupsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< com.google.ads.googleads.v17.services.YouTubeSelectLineUp, com.google.ads.googleads.v17.services.YouTubeSelectLineUp.Builder, com.google.ads.googleads.v17.services.YouTubeSelectLineUpOrBuilder>( youtubeSelectLineups_, ((bitField0_ & 0x00000010) != 0), getParentForChildren(), isClean()); youtubeSelectLineups_ = null; } return youtubeSelectLineupsBuilder_; } private com.google.ads.googleads.v17.services.SurfaceTargetingCombinations surfaceTargeting_; private com.google.protobuf.SingleFieldBuilderV3< com.google.ads.googleads.v17.services.SurfaceTargetingCombinations, com.google.ads.googleads.v17.services.SurfaceTargetingCombinations.Builder, com.google.ads.googleads.v17.services.SurfaceTargetingCombinationsOrBuilder> surfaceTargetingBuilder_; /** *
     * Targetable surface combinations for the ad product.
     * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; * @return Whether the surfaceTargeting field is set. */ public boolean hasSurfaceTargeting() { return ((bitField0_ & 0x00000020) != 0); } /** *
     * Targetable surface combinations for the ad product.
     * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; * @return The surfaceTargeting. */ public com.google.ads.googleads.v17.services.SurfaceTargetingCombinations getSurfaceTargeting() { if (surfaceTargetingBuilder_ == null) { return surfaceTargeting_ == null ? com.google.ads.googleads.v17.services.SurfaceTargetingCombinations.getDefaultInstance() : surfaceTargeting_; } else { return surfaceTargetingBuilder_.getMessage(); } } /** *
     * Targetable surface combinations for the ad product.
     * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; */ public Builder setSurfaceTargeting(com.google.ads.googleads.v17.services.SurfaceTargetingCombinations value) { if (surfaceTargetingBuilder_ == null) { if (value == null) { throw new NullPointerException(); } surfaceTargeting_ = value; } else { surfaceTargetingBuilder_.setMessage(value); } bitField0_ |= 0x00000020; onChanged(); return this; } /** *
     * Targetable surface combinations for the ad product.
     * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; */ public Builder setSurfaceTargeting( com.google.ads.googleads.v17.services.SurfaceTargetingCombinations.Builder builderForValue) { if (surfaceTargetingBuilder_ == null) { surfaceTargeting_ = builderForValue.build(); } else { surfaceTargetingBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000020; onChanged(); return this; } /** *
     * Targetable surface combinations for the ad product.
     * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; */ public Builder mergeSurfaceTargeting(com.google.ads.googleads.v17.services.SurfaceTargetingCombinations value) { if (surfaceTargetingBuilder_ == null) { if (((bitField0_ & 0x00000020) != 0) && surfaceTargeting_ != null && surfaceTargeting_ != com.google.ads.googleads.v17.services.SurfaceTargetingCombinations.getDefaultInstance()) { getSurfaceTargetingBuilder().mergeFrom(value); } else { surfaceTargeting_ = value; } } else { surfaceTargetingBuilder_.mergeFrom(value); } if (surfaceTargeting_ != null) { bitField0_ |= 0x00000020; onChanged(); } return this; } /** *
     * Targetable surface combinations for the ad product.
     * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; */ public Builder clearSurfaceTargeting() { bitField0_ = (bitField0_ & ~0x00000020); surfaceTargeting_ = null; if (surfaceTargetingBuilder_ != null) { surfaceTargetingBuilder_.dispose(); surfaceTargetingBuilder_ = null; } onChanged(); return this; } /** *
     * Targetable surface combinations for the ad product.
     * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; */ public com.google.ads.googleads.v17.services.SurfaceTargetingCombinations.Builder getSurfaceTargetingBuilder() { bitField0_ |= 0x00000020; onChanged(); return getSurfaceTargetingFieldBuilder().getBuilder(); } /** *
     * Targetable surface combinations for the ad product.
     * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; */ public com.google.ads.googleads.v17.services.SurfaceTargetingCombinationsOrBuilder getSurfaceTargetingOrBuilder() { if (surfaceTargetingBuilder_ != null) { return surfaceTargetingBuilder_.getMessageOrBuilder(); } else { return surfaceTargeting_ == null ? com.google.ads.googleads.v17.services.SurfaceTargetingCombinations.getDefaultInstance() : surfaceTargeting_; } } /** *
     * Targetable surface combinations for the ad product.
     * 
* * .google.ads.googleads.v17.services.SurfaceTargetingCombinations surface_targeting = 6; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.ads.googleads.v17.services.SurfaceTargetingCombinations, com.google.ads.googleads.v17.services.SurfaceTargetingCombinations.Builder, com.google.ads.googleads.v17.services.SurfaceTargetingCombinationsOrBuilder> getSurfaceTargetingFieldBuilder() { if (surfaceTargetingBuilder_ == null) { surfaceTargetingBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.ads.googleads.v17.services.SurfaceTargetingCombinations, com.google.ads.googleads.v17.services.SurfaceTargetingCombinations.Builder, com.google.ads.googleads.v17.services.SurfaceTargetingCombinationsOrBuilder>( getSurfaceTargeting(), getParentForChildren(), isClean()); surfaceTargeting_ = null; } return surfaceTargetingBuilder_; } @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.PlannableTargeting) } // @@protoc_insertion_point(class_scope:google.ads.googleads.v17.services.PlannableTargeting) private static final com.google.ads.googleads.v17.services.PlannableTargeting DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.ads.googleads.v17.services.PlannableTargeting(); } public static com.google.ads.googleads.v17.services.PlannableTargeting getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public PlannableTargeting 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.PlannableTargeting getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy