com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of google-ads-stubs-v10 Show documentation
Show all versions of google-ads-stubs-v10 Show documentation
Stubs for GAAPI version google-ads-stubs-v10
The newest version!
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/ads/googleads/v10/services/keyword_plan_service.proto
package com.google.ads.googleads.v10.services;
/**
*
* The weekly time series forecast for the keyword plan campaign.
*
*
* Protobuf type {@code google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast}
*/
public final class KeywordPlanWeeklyTimeSeriesForecast extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast)
KeywordPlanWeeklyTimeSeriesForecastOrBuilder {
private static final long serialVersionUID = 0L;
// Use KeywordPlanWeeklyTimeSeriesForecast.newBuilder() to construct.
private KeywordPlanWeeklyTimeSeriesForecast(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private KeywordPlanWeeklyTimeSeriesForecast() {
keywordPlanCampaign_ = "";
weeklyForecasts_ = java.util.Collections.emptyList();
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new KeywordPlanWeeklyTimeSeriesForecast();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v10.services.KeywordPlanServiceProto.internal_static_google_ads_googleads_v10_services_KeywordPlanWeeklyTimeSeriesForecast_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v10.services.KeywordPlanServiceProto.internal_static_google_ads_googleads_v10_services_KeywordPlanWeeklyTimeSeriesForecast_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast.class, com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast.Builder.class);
}
private int bitField0_;
public static final int KEYWORD_PLAN_CAMPAIGN_FIELD_NUMBER = 1;
private volatile java.lang.Object keywordPlanCampaign_;
/**
*
* The resource name of the Keyword Plan campaign related to the forecast.
* `customers/{customer_id}/keywordPlanCampaigns/{keyword_plan_campaign_id}`
*
*
* optional string keyword_plan_campaign = 1;
* @return Whether the keywordPlanCampaign field is set.
*/
@java.lang.Override
public boolean hasKeywordPlanCampaign() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* The resource name of the Keyword Plan campaign related to the forecast.
* `customers/{customer_id}/keywordPlanCampaigns/{keyword_plan_campaign_id}`
*
*
* optional string keyword_plan_campaign = 1;
* @return The keywordPlanCampaign.
*/
@java.lang.Override
public java.lang.String getKeywordPlanCampaign() {
java.lang.Object ref = keywordPlanCampaign_;
if (ref instanceof java.lang.String) {
return (java.lang.String) ref;
} else {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
keywordPlanCampaign_ = s;
return s;
}
}
/**
*
* The resource name of the Keyword Plan campaign related to the forecast.
* `customers/{customer_id}/keywordPlanCampaigns/{keyword_plan_campaign_id}`
*
*
* optional string keyword_plan_campaign = 1;
* @return The bytes for keywordPlanCampaign.
*/
@java.lang.Override
public com.google.protobuf.ByteString
getKeywordPlanCampaignBytes() {
java.lang.Object ref = keywordPlanCampaign_;
if (ref instanceof java.lang.String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
keywordPlanCampaign_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
public static final int WEEKLY_FORECASTS_FIELD_NUMBER = 2;
private java.util.List weeklyForecasts_;
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
@java.lang.Override
public java.util.List getWeeklyForecastsList() {
return weeklyForecasts_;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
@java.lang.Override
public java.util.List extends com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecastOrBuilder>
getWeeklyForecastsOrBuilderList() {
return weeklyForecasts_;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
@java.lang.Override
public int getWeeklyForecastsCount() {
return weeklyForecasts_.size();
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
@java.lang.Override
public com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast getWeeklyForecasts(int index) {
return weeklyForecasts_.get(index);
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
@java.lang.Override
public com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecastOrBuilder getWeeklyForecastsOrBuilder(
int index) {
return weeklyForecasts_.get(index);
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (((bitField0_ & 0x00000001) != 0)) {
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, keywordPlanCampaign_);
}
for (int i = 0; i < weeklyForecasts_.size(); i++) {
output.writeMessage(2, weeklyForecasts_.get(i));
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (((bitField0_ & 0x00000001) != 0)) {
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, keywordPlanCampaign_);
}
for (int i = 0; i < weeklyForecasts_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, weeklyForecasts_.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.v10.services.KeywordPlanWeeklyTimeSeriesForecast)) {
return super.equals(obj);
}
com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast other = (com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast) obj;
if (hasKeywordPlanCampaign() != other.hasKeywordPlanCampaign()) return false;
if (hasKeywordPlanCampaign()) {
if (!getKeywordPlanCampaign()
.equals(other.getKeywordPlanCampaign())) return false;
}
if (!getWeeklyForecastsList()
.equals(other.getWeeklyForecastsList())) 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 (hasKeywordPlanCampaign()) {
hash = (37 * hash) + KEYWORD_PLAN_CAMPAIGN_FIELD_NUMBER;
hash = (53 * hash) + getKeywordPlanCampaign().hashCode();
}
if (getWeeklyForecastsCount() > 0) {
hash = (37 * hash) + WEEKLY_FORECASTS_FIELD_NUMBER;
hash = (53 * hash) + getWeeklyForecastsList().hashCode();
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast 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.v10.services.KeywordPlanWeeklyTimeSeriesForecast parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast 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.v10.services.KeywordPlanWeeklyTimeSeriesForecast parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast 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.v10.services.KeywordPlanWeeklyTimeSeriesForecast parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast 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.v10.services.KeywordPlanWeeklyTimeSeriesForecast parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast 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.v10.services.KeywordPlanWeeklyTimeSeriesForecast 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 weekly time series forecast for the keyword plan campaign.
*
*
* Protobuf type {@code google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast)
com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecastOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return com.google.ads.googleads.v10.services.KeywordPlanServiceProto.internal_static_google_ads_googleads_v10_services_KeywordPlanWeeklyTimeSeriesForecast_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return com.google.ads.googleads.v10.services.KeywordPlanServiceProto.internal_static_google_ads_googleads_v10_services_KeywordPlanWeeklyTimeSeriesForecast_fieldAccessorTable
.ensureFieldAccessorsInitialized(
com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast.class, com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast.Builder.class);
}
// Construct using com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
keywordPlanCampaign_ = "";
bitField0_ = (bitField0_ & ~0x00000001);
if (weeklyForecastsBuilder_ == null) {
weeklyForecasts_ = java.util.Collections.emptyList();
} else {
weeklyForecasts_ = null;
weeklyForecastsBuilder_.clear();
}
bitField0_ = (bitField0_ & ~0x00000002);
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return com.google.ads.googleads.v10.services.KeywordPlanServiceProto.internal_static_google_ads_googleads_v10_services_KeywordPlanWeeklyTimeSeriesForecast_descriptor;
}
@java.lang.Override
public com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast getDefaultInstanceForType() {
return com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast.getDefaultInstance();
}
@java.lang.Override
public com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast build() {
com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast buildPartial() {
com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast result = new com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast(this);
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (((from_bitField0_ & 0x00000001) != 0)) {
to_bitField0_ |= 0x00000001;
}
result.keywordPlanCampaign_ = keywordPlanCampaign_;
if (weeklyForecastsBuilder_ == null) {
if (((bitField0_ & 0x00000002) != 0)) {
weeklyForecasts_ = java.util.Collections.unmodifiableList(weeklyForecasts_);
bitField0_ = (bitField0_ & ~0x00000002);
}
result.weeklyForecasts_ = weeklyForecasts_;
} else {
result.weeklyForecasts_ = weeklyForecastsBuilder_.build();
}
result.bitField0_ = to_bitField0_;
onBuilt();
return result;
}
@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.v10.services.KeywordPlanWeeklyTimeSeriesForecast) {
return mergeFrom((com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast other) {
if (other == com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast.getDefaultInstance()) return this;
if (other.hasKeywordPlanCampaign()) {
bitField0_ |= 0x00000001;
keywordPlanCampaign_ = other.keywordPlanCampaign_;
onChanged();
}
if (weeklyForecastsBuilder_ == null) {
if (!other.weeklyForecasts_.isEmpty()) {
if (weeklyForecasts_.isEmpty()) {
weeklyForecasts_ = other.weeklyForecasts_;
bitField0_ = (bitField0_ & ~0x00000002);
} else {
ensureWeeklyForecastsIsMutable();
weeklyForecasts_.addAll(other.weeklyForecasts_);
}
onChanged();
}
} else {
if (!other.weeklyForecasts_.isEmpty()) {
if (weeklyForecastsBuilder_.isEmpty()) {
weeklyForecastsBuilder_.dispose();
weeklyForecastsBuilder_ = null;
weeklyForecasts_ = other.weeklyForecasts_;
bitField0_ = (bitField0_ & ~0x00000002);
weeklyForecastsBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getWeeklyForecastsFieldBuilder() : null;
} else {
weeklyForecastsBuilder_.addAllMessages(other.weeklyForecasts_);
}
}
}
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: {
keywordPlanCampaign_ = input.readStringRequireUtf8();
bitField0_ |= 0x00000001;
break;
} // case 10
case 18: {
com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast m =
input.readMessage(
com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.parser(),
extensionRegistry);
if (weeklyForecastsBuilder_ == null) {
ensureWeeklyForecastsIsMutable();
weeklyForecasts_.add(m);
} else {
weeklyForecastsBuilder_.addMessage(m);
}
break;
} // case 18
default: {
if (!super.parseUnknownField(input, extensionRegistry, tag)) {
done = true; // was an endgroup tag
}
break;
} // default:
} // switch (tag)
} // while (!done)
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.unwrapIOException();
} finally {
onChanged();
} // finally
return this;
}
private int bitField0_;
private java.lang.Object keywordPlanCampaign_ = "";
/**
*
* The resource name of the Keyword Plan campaign related to the forecast.
* `customers/{customer_id}/keywordPlanCampaigns/{keyword_plan_campaign_id}`
*
*
* optional string keyword_plan_campaign = 1;
* @return Whether the keywordPlanCampaign field is set.
*/
public boolean hasKeywordPlanCampaign() {
return ((bitField0_ & 0x00000001) != 0);
}
/**
*
* The resource name of the Keyword Plan campaign related to the forecast.
* `customers/{customer_id}/keywordPlanCampaigns/{keyword_plan_campaign_id}`
*
*
* optional string keyword_plan_campaign = 1;
* @return The keywordPlanCampaign.
*/
public java.lang.String getKeywordPlanCampaign() {
java.lang.Object ref = keywordPlanCampaign_;
if (!(ref instanceof java.lang.String)) {
com.google.protobuf.ByteString bs =
(com.google.protobuf.ByteString) ref;
java.lang.String s = bs.toStringUtf8();
keywordPlanCampaign_ = s;
return s;
} else {
return (java.lang.String) ref;
}
}
/**
*
* The resource name of the Keyword Plan campaign related to the forecast.
* `customers/{customer_id}/keywordPlanCampaigns/{keyword_plan_campaign_id}`
*
*
* optional string keyword_plan_campaign = 1;
* @return The bytes for keywordPlanCampaign.
*/
public com.google.protobuf.ByteString
getKeywordPlanCampaignBytes() {
java.lang.Object ref = keywordPlanCampaign_;
if (ref instanceof String) {
com.google.protobuf.ByteString b =
com.google.protobuf.ByteString.copyFromUtf8(
(java.lang.String) ref);
keywordPlanCampaign_ = b;
return b;
} else {
return (com.google.protobuf.ByteString) ref;
}
}
/**
*
* The resource name of the Keyword Plan campaign related to the forecast.
* `customers/{customer_id}/keywordPlanCampaigns/{keyword_plan_campaign_id}`
*
*
* optional string keyword_plan_campaign = 1;
* @param value The keywordPlanCampaign to set.
* @return This builder for chaining.
*/
public Builder setKeywordPlanCampaign(
java.lang.String value) {
if (value == null) {
throw new NullPointerException();
}
bitField0_ |= 0x00000001;
keywordPlanCampaign_ = value;
onChanged();
return this;
}
/**
*
* The resource name of the Keyword Plan campaign related to the forecast.
* `customers/{customer_id}/keywordPlanCampaigns/{keyword_plan_campaign_id}`
*
*
* optional string keyword_plan_campaign = 1;
* @return This builder for chaining.
*/
public Builder clearKeywordPlanCampaign() {
bitField0_ = (bitField0_ & ~0x00000001);
keywordPlanCampaign_ = getDefaultInstance().getKeywordPlanCampaign();
onChanged();
return this;
}
/**
*
* The resource name of the Keyword Plan campaign related to the forecast.
* `customers/{customer_id}/keywordPlanCampaigns/{keyword_plan_campaign_id}`
*
*
* optional string keyword_plan_campaign = 1;
* @param value The bytes for keywordPlanCampaign to set.
* @return This builder for chaining.
*/
public Builder setKeywordPlanCampaignBytes(
com.google.protobuf.ByteString value) {
if (value == null) {
throw new NullPointerException();
}
checkByteStringIsUtf8(value);
bitField0_ |= 0x00000001;
keywordPlanCampaign_ = value;
onChanged();
return this;
}
private java.util.List weeklyForecasts_ =
java.util.Collections.emptyList();
private void ensureWeeklyForecastsIsMutable() {
if (!((bitField0_ & 0x00000002) != 0)) {
weeklyForecasts_ = new java.util.ArrayList(weeklyForecasts_);
bitField0_ |= 0x00000002;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.Builder, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecastOrBuilder> weeklyForecastsBuilder_;
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public java.util.List getWeeklyForecastsList() {
if (weeklyForecastsBuilder_ == null) {
return java.util.Collections.unmodifiableList(weeklyForecasts_);
} else {
return weeklyForecastsBuilder_.getMessageList();
}
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public int getWeeklyForecastsCount() {
if (weeklyForecastsBuilder_ == null) {
return weeklyForecasts_.size();
} else {
return weeklyForecastsBuilder_.getCount();
}
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast getWeeklyForecasts(int index) {
if (weeklyForecastsBuilder_ == null) {
return weeklyForecasts_.get(index);
} else {
return weeklyForecastsBuilder_.getMessage(index);
}
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public Builder setWeeklyForecasts(
int index, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast value) {
if (weeklyForecastsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureWeeklyForecastsIsMutable();
weeklyForecasts_.set(index, value);
onChanged();
} else {
weeklyForecastsBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public Builder setWeeklyForecasts(
int index, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.Builder builderForValue) {
if (weeklyForecastsBuilder_ == null) {
ensureWeeklyForecastsIsMutable();
weeklyForecasts_.set(index, builderForValue.build());
onChanged();
} else {
weeklyForecastsBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public Builder addWeeklyForecasts(com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast value) {
if (weeklyForecastsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureWeeklyForecastsIsMutable();
weeklyForecasts_.add(value);
onChanged();
} else {
weeklyForecastsBuilder_.addMessage(value);
}
return this;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public Builder addWeeklyForecasts(
int index, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast value) {
if (weeklyForecastsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureWeeklyForecastsIsMutable();
weeklyForecasts_.add(index, value);
onChanged();
} else {
weeklyForecastsBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public Builder addWeeklyForecasts(
com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.Builder builderForValue) {
if (weeklyForecastsBuilder_ == null) {
ensureWeeklyForecastsIsMutable();
weeklyForecasts_.add(builderForValue.build());
onChanged();
} else {
weeklyForecastsBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public Builder addWeeklyForecasts(
int index, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.Builder builderForValue) {
if (weeklyForecastsBuilder_ == null) {
ensureWeeklyForecastsIsMutable();
weeklyForecasts_.add(index, builderForValue.build());
onChanged();
} else {
weeklyForecastsBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public Builder addAllWeeklyForecasts(
java.lang.Iterable extends com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast> values) {
if (weeklyForecastsBuilder_ == null) {
ensureWeeklyForecastsIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, weeklyForecasts_);
onChanged();
} else {
weeklyForecastsBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public Builder clearWeeklyForecasts() {
if (weeklyForecastsBuilder_ == null) {
weeklyForecasts_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000002);
onChanged();
} else {
weeklyForecastsBuilder_.clear();
}
return this;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public Builder removeWeeklyForecasts(int index) {
if (weeklyForecastsBuilder_ == null) {
ensureWeeklyForecastsIsMutable();
weeklyForecasts_.remove(index);
onChanged();
} else {
weeklyForecastsBuilder_.remove(index);
}
return this;
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.Builder getWeeklyForecastsBuilder(
int index) {
return getWeeklyForecastsFieldBuilder().getBuilder(index);
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecastOrBuilder getWeeklyForecastsOrBuilder(
int index) {
if (weeklyForecastsBuilder_ == null) {
return weeklyForecasts_.get(index); } else {
return weeklyForecastsBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public java.util.List extends com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecastOrBuilder>
getWeeklyForecastsOrBuilderList() {
if (weeklyForecastsBuilder_ != null) {
return weeklyForecastsBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(weeklyForecasts_);
}
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.Builder addWeeklyForecastsBuilder() {
return getWeeklyForecastsFieldBuilder().addBuilder(
com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.getDefaultInstance());
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.Builder addWeeklyForecastsBuilder(
int index) {
return getWeeklyForecastsFieldBuilder().addBuilder(
index, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.getDefaultInstance());
}
/**
*
* The forecasts for the Keyword Plan campaign at different max CPC bids.
*
*
* repeated .google.ads.googleads.v10.services.KeywordPlanWeeklyForecast weekly_forecasts = 2;
*/
public java.util.List
getWeeklyForecastsBuilderList() {
return getWeeklyForecastsFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.Builder, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecastOrBuilder>
getWeeklyForecastsFieldBuilder() {
if (weeklyForecastsBuilder_ == null) {
weeklyForecastsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecast.Builder, com.google.ads.googleads.v10.services.KeywordPlanWeeklyForecastOrBuilder>(
weeklyForecasts_,
((bitField0_ & 0x00000002) != 0),
getParentForChildren(),
isClean());
weeklyForecasts_ = null;
}
return weeklyForecastsBuilder_;
}
@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.v10.services.KeywordPlanWeeklyTimeSeriesForecast)
}
// @@protoc_insertion_point(class_scope:google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast)
private static final com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast();
}
public static com.google.ads.googleads.v10.services.KeywordPlanWeeklyTimeSeriesForecast getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public KeywordPlanWeeklyTimeSeriesForecast 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.v10.services.KeywordPlanWeeklyTimeSeriesForecast getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy