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

com.google.ads.googleads.v10.resources.CampaignBidModifier Maven / Gradle / Ivy

// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/ads/googleads/v10/resources/campaign_bid_modifier.proto

package com.google.ads.googleads.v10.resources;

/**
 * 
 * Represents a bid-modifiable only criterion at the campaign level.
 * 
* * Protobuf type {@code google.ads.googleads.v10.resources.CampaignBidModifier} */ public final class CampaignBidModifier extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.ads.googleads.v10.resources.CampaignBidModifier) CampaignBidModifierOrBuilder { private static final long serialVersionUID = 0L; // Use CampaignBidModifier.newBuilder() to construct. private CampaignBidModifier(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private CampaignBidModifier() { resourceName_ = ""; campaign_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new CampaignBidModifier(); } @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.resources.CampaignBidModifierProto.internal_static_google_ads_googleads_v10_resources_CampaignBidModifier_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.ads.googleads.v10.resources.CampaignBidModifierProto.internal_static_google_ads_googleads_v10_resources_CampaignBidModifier_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.ads.googleads.v10.resources.CampaignBidModifier.class, com.google.ads.googleads.v10.resources.CampaignBidModifier.Builder.class); } private int bitField0_; private int criterionCase_ = 0; private java.lang.Object criterion_; public enum CriterionCase implements com.google.protobuf.Internal.EnumLite, com.google.protobuf.AbstractMessage.InternalOneOfEnum { INTERACTION_TYPE(5), CRITERION_NOT_SET(0); private final int value; private CriterionCase(int value) { this.value = value; } /** * @param value The number of the enum to look for. * @return The enum associated with the given number. * @deprecated Use {@link #forNumber(int)} instead. */ @java.lang.Deprecated public static CriterionCase valueOf(int value) { return forNumber(value); } public static CriterionCase forNumber(int value) { switch (value) { case 5: return INTERACTION_TYPE; case 0: return CRITERION_NOT_SET; default: return null; } } public int getNumber() { return this.value; } }; public CriterionCase getCriterionCase() { return CriterionCase.forNumber( criterionCase_); } public static final int RESOURCE_NAME_FIELD_NUMBER = 1; private volatile java.lang.Object resourceName_; /** *
   * Immutable. The resource name of the campaign bid modifier.
   * Campaign bid modifier resource names have the form:
   * `customers/{customer_id}/campaignBidModifiers/{campaign_id}~{criterion_id}`
   * 
* * string resource_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return The resourceName. */ @java.lang.Override public java.lang.String getResourceName() { java.lang.Object ref = resourceName_; 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(); resourceName_ = s; return s; } } /** *
   * Immutable. The resource name of the campaign bid modifier.
   * Campaign bid modifier resource names have the form:
   * `customers/{customer_id}/campaignBidModifiers/{campaign_id}~{criterion_id}`
   * 
* * string resource_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return The bytes for resourceName. */ @java.lang.Override public com.google.protobuf.ByteString getResourceNameBytes() { java.lang.Object ref = resourceName_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); resourceName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int CAMPAIGN_FIELD_NUMBER = 6; private volatile java.lang.Object campaign_; /** *
   * Output only. The campaign to which this criterion belongs.
   * 
* * optional string campaign = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return Whether the campaign field is set. */ @java.lang.Override public boolean hasCampaign() { return ((bitField0_ & 0x00000001) != 0); } /** *
   * Output only. The campaign to which this criterion belongs.
   * 
* * optional string campaign = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return The campaign. */ @java.lang.Override public java.lang.String getCampaign() { java.lang.Object ref = campaign_; 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(); campaign_ = s; return s; } } /** *
   * Output only. The campaign to which this criterion belongs.
   * 
* * optional string campaign = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return The bytes for campaign. */ @java.lang.Override public com.google.protobuf.ByteString getCampaignBytes() { java.lang.Object ref = campaign_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); campaign_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int CRITERION_ID_FIELD_NUMBER = 7; private long criterionId_; /** *
   * Output only. The ID of the criterion to bid modify.
   * This field is ignored for mutates.
   * 
* * optional int64 criterion_id = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return Whether the criterionId field is set. */ @java.lang.Override public boolean hasCriterionId() { return ((bitField0_ & 0x00000002) != 0); } /** *
   * Output only. The ID of the criterion to bid modify.
   * This field is ignored for mutates.
   * 
* * optional int64 criterion_id = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The criterionId. */ @java.lang.Override public long getCriterionId() { return criterionId_; } public static final int BID_MODIFIER_FIELD_NUMBER = 8; private double bidModifier_; /** *
   * The modifier for the bid when the criterion matches.
   * 
* * optional double bid_modifier = 8; * @return Whether the bidModifier field is set. */ @java.lang.Override public boolean hasBidModifier() { return ((bitField0_ & 0x00000004) != 0); } /** *
   * The modifier for the bid when the criterion matches.
   * 
* * optional double bid_modifier = 8; * @return The bidModifier. */ @java.lang.Override public double getBidModifier() { return bidModifier_; } public static final int INTERACTION_TYPE_FIELD_NUMBER = 5; /** *
   * Immutable. Criterion for interaction type. Only supported for search campaigns.
   * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; * @return Whether the interactionType field is set. */ @java.lang.Override public boolean hasInteractionType() { return criterionCase_ == 5; } /** *
   * Immutable. Criterion for interaction type. Only supported for search campaigns.
   * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; * @return The interactionType. */ @java.lang.Override public com.google.ads.googleads.v10.common.InteractionTypeInfo getInteractionType() { if (criterionCase_ == 5) { return (com.google.ads.googleads.v10.common.InteractionTypeInfo) criterion_; } return com.google.ads.googleads.v10.common.InteractionTypeInfo.getDefaultInstance(); } /** *
   * Immutable. Criterion for interaction type. Only supported for search campaigns.
   * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; */ @java.lang.Override public com.google.ads.googleads.v10.common.InteractionTypeInfoOrBuilder getInteractionTypeOrBuilder() { if (criterionCase_ == 5) { return (com.google.ads.googleads.v10.common.InteractionTypeInfo) criterion_; } return com.google.ads.googleads.v10.common.InteractionTypeInfo.getDefaultInstance(); } private byte memoizedIsInitialized = -1; @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; if (isInitialized == 0) return false; memoizedIsInitialized = 1; return true; } @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceName_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resourceName_); } if (criterionCase_ == 5) { output.writeMessage(5, (com.google.ads.googleads.v10.common.InteractionTypeInfo) criterion_); } if (((bitField0_ & 0x00000001) != 0)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 6, campaign_); } if (((bitField0_ & 0x00000002) != 0)) { output.writeInt64(7, criterionId_); } if (((bitField0_ & 0x00000004) != 0)) { output.writeDouble(8, bidModifier_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceName_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resourceName_); } if (criterionCase_ == 5) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(5, (com.google.ads.googleads.v10.common.InteractionTypeInfo) criterion_); } if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, campaign_); } if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(7, criterionId_); } if (((bitField0_ & 0x00000004) != 0)) { size += com.google.protobuf.CodedOutputStream .computeDoubleSize(8, bidModifier_); } 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.resources.CampaignBidModifier)) { return super.equals(obj); } com.google.ads.googleads.v10.resources.CampaignBidModifier other = (com.google.ads.googleads.v10.resources.CampaignBidModifier) obj; if (!getResourceName() .equals(other.getResourceName())) return false; if (hasCampaign() != other.hasCampaign()) return false; if (hasCampaign()) { if (!getCampaign() .equals(other.getCampaign())) return false; } if (hasCriterionId() != other.hasCriterionId()) return false; if (hasCriterionId()) { if (getCriterionId() != other.getCriterionId()) return false; } if (hasBidModifier() != other.hasBidModifier()) return false; if (hasBidModifier()) { if (java.lang.Double.doubleToLongBits(getBidModifier()) != java.lang.Double.doubleToLongBits( other.getBidModifier())) return false; } if (!getCriterionCase().equals(other.getCriterionCase())) return false; switch (criterionCase_) { case 5: if (!getInteractionType() .equals(other.getInteractionType())) return false; break; case 0: default: } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + RESOURCE_NAME_FIELD_NUMBER; hash = (53 * hash) + getResourceName().hashCode(); if (hasCampaign()) { hash = (37 * hash) + CAMPAIGN_FIELD_NUMBER; hash = (53 * hash) + getCampaign().hashCode(); } if (hasCriterionId()) { hash = (37 * hash) + CRITERION_ID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getCriterionId()); } if (hasBidModifier()) { hash = (37 * hash) + BID_MODIFIER_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( java.lang.Double.doubleToLongBits(getBidModifier())); } switch (criterionCase_) { case 5: hash = (37 * hash) + INTERACTION_TYPE_FIELD_NUMBER; hash = (53 * hash) + getInteractionType().hashCode(); break; case 0: default: } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.ads.googleads.v10.resources.CampaignBidModifier parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.ads.googleads.v10.resources.CampaignBidModifier 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.resources.CampaignBidModifier parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.ads.googleads.v10.resources.CampaignBidModifier 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.resources.CampaignBidModifier parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.ads.googleads.v10.resources.CampaignBidModifier 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.resources.CampaignBidModifier parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.google.ads.googleads.v10.resources.CampaignBidModifier 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.resources.CampaignBidModifier parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static com.google.ads.googleads.v10.resources.CampaignBidModifier 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.resources.CampaignBidModifier 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.resources.CampaignBidModifier 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.resources.CampaignBidModifier 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; } /** *
   * Represents a bid-modifiable only criterion at the campaign level.
   * 
* * Protobuf type {@code google.ads.googleads.v10.resources.CampaignBidModifier} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.ads.googleads.v10.resources.CampaignBidModifier) com.google.ads.googleads.v10.resources.CampaignBidModifierOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.ads.googleads.v10.resources.CampaignBidModifierProto.internal_static_google_ads_googleads_v10_resources_CampaignBidModifier_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.ads.googleads.v10.resources.CampaignBidModifierProto.internal_static_google_ads_googleads_v10_resources_CampaignBidModifier_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.ads.googleads.v10.resources.CampaignBidModifier.class, com.google.ads.googleads.v10.resources.CampaignBidModifier.Builder.class); } // Construct using com.google.ads.googleads.v10.resources.CampaignBidModifier.newBuilder() private Builder() { } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); resourceName_ = ""; campaign_ = ""; bitField0_ = (bitField0_ & ~0x00000001); criterionId_ = 0L; bitField0_ = (bitField0_ & ~0x00000002); bidModifier_ = 0D; bitField0_ = (bitField0_ & ~0x00000004); if (interactionTypeBuilder_ != null) { interactionTypeBuilder_.clear(); } criterionCase_ = 0; criterion_ = null; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.ads.googleads.v10.resources.CampaignBidModifierProto.internal_static_google_ads_googleads_v10_resources_CampaignBidModifier_descriptor; } @java.lang.Override public com.google.ads.googleads.v10.resources.CampaignBidModifier getDefaultInstanceForType() { return com.google.ads.googleads.v10.resources.CampaignBidModifier.getDefaultInstance(); } @java.lang.Override public com.google.ads.googleads.v10.resources.CampaignBidModifier build() { com.google.ads.googleads.v10.resources.CampaignBidModifier result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.ads.googleads.v10.resources.CampaignBidModifier buildPartial() { com.google.ads.googleads.v10.resources.CampaignBidModifier result = new com.google.ads.googleads.v10.resources.CampaignBidModifier(this); int from_bitField0_ = bitField0_; int to_bitField0_ = 0; result.resourceName_ = resourceName_; if (((from_bitField0_ & 0x00000001) != 0)) { to_bitField0_ |= 0x00000001; } result.campaign_ = campaign_; if (((from_bitField0_ & 0x00000002) != 0)) { result.criterionId_ = criterionId_; to_bitField0_ |= 0x00000002; } if (((from_bitField0_ & 0x00000004) != 0)) { result.bidModifier_ = bidModifier_; to_bitField0_ |= 0x00000004; } if (criterionCase_ == 5) { if (interactionTypeBuilder_ == null) { result.criterion_ = criterion_; } else { result.criterion_ = interactionTypeBuilder_.build(); } } result.bitField0_ = to_bitField0_; result.criterionCase_ = criterionCase_; 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.resources.CampaignBidModifier) { return mergeFrom((com.google.ads.googleads.v10.resources.CampaignBidModifier)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.ads.googleads.v10.resources.CampaignBidModifier other) { if (other == com.google.ads.googleads.v10.resources.CampaignBidModifier.getDefaultInstance()) return this; if (!other.getResourceName().isEmpty()) { resourceName_ = other.resourceName_; onChanged(); } if (other.hasCampaign()) { bitField0_ |= 0x00000001; campaign_ = other.campaign_; onChanged(); } if (other.hasCriterionId()) { setCriterionId(other.getCriterionId()); } if (other.hasBidModifier()) { setBidModifier(other.getBidModifier()); } switch (other.getCriterionCase()) { case INTERACTION_TYPE: { mergeInteractionType(other.getInteractionType()); break; } case CRITERION_NOT_SET: { break; } } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { resourceName_ = input.readStringRequireUtf8(); break; } // case 10 case 42: { input.readMessage( getInteractionTypeFieldBuilder().getBuilder(), extensionRegistry); criterionCase_ = 5; break; } // case 42 case 50: { campaign_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 50 case 56: { criterionId_ = input.readInt64(); bitField0_ |= 0x00000002; break; } // case 56 case 65: { bidModifier_ = input.readDouble(); bitField0_ |= 0x00000004; break; } // case 65 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 criterionCase_ = 0; private java.lang.Object criterion_; public CriterionCase getCriterionCase() { return CriterionCase.forNumber( criterionCase_); } public Builder clearCriterion() { criterionCase_ = 0; criterion_ = null; onChanged(); return this; } private int bitField0_; private java.lang.Object resourceName_ = ""; /** *
     * Immutable. The resource name of the campaign bid modifier.
     * Campaign bid modifier resource names have the form:
     * `customers/{customer_id}/campaignBidModifiers/{campaign_id}~{criterion_id}`
     * 
* * string resource_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return The resourceName. */ public java.lang.String getResourceName() { java.lang.Object ref = resourceName_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); resourceName_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     * Immutable. The resource name of the campaign bid modifier.
     * Campaign bid modifier resource names have the form:
     * `customers/{customer_id}/campaignBidModifiers/{campaign_id}~{criterion_id}`
     * 
* * string resource_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return The bytes for resourceName. */ public com.google.protobuf.ByteString getResourceNameBytes() { java.lang.Object ref = resourceName_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); resourceName_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     * Immutable. The resource name of the campaign bid modifier.
     * Campaign bid modifier resource names have the form:
     * `customers/{customer_id}/campaignBidModifiers/{campaign_id}~{criterion_id}`
     * 
* * string resource_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @param value The resourceName to set. * @return This builder for chaining. */ public Builder setResourceName( java.lang.String value) { if (value == null) { throw new NullPointerException(); } resourceName_ = value; onChanged(); return this; } /** *
     * Immutable. The resource name of the campaign bid modifier.
     * Campaign bid modifier resource names have the form:
     * `customers/{customer_id}/campaignBidModifiers/{campaign_id}~{criterion_id}`
     * 
* * string resource_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return This builder for chaining. */ public Builder clearResourceName() { resourceName_ = getDefaultInstance().getResourceName(); onChanged(); return this; } /** *
     * Immutable. The resource name of the campaign bid modifier.
     * Campaign bid modifier resource names have the form:
     * `customers/{customer_id}/campaignBidModifiers/{campaign_id}~{criterion_id}`
     * 
* * string resource_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @param value The bytes for resourceName to set. * @return This builder for chaining. */ public Builder setResourceNameBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); resourceName_ = value; onChanged(); return this; } private java.lang.Object campaign_ = ""; /** *
     * Output only. The campaign to which this criterion belongs.
     * 
* * optional string campaign = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return Whether the campaign field is set. */ public boolean hasCampaign() { return ((bitField0_ & 0x00000001) != 0); } /** *
     * Output only. The campaign to which this criterion belongs.
     * 
* * optional string campaign = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return The campaign. */ public java.lang.String getCampaign() { java.lang.Object ref = campaign_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); campaign_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     * Output only. The campaign to which this criterion belongs.
     * 
* * optional string campaign = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return The bytes for campaign. */ public com.google.protobuf.ByteString getCampaignBytes() { java.lang.Object ref = campaign_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); campaign_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     * Output only. The campaign to which this criterion belongs.
     * 
* * optional string campaign = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @param value The campaign to set. * @return This builder for chaining. */ public Builder setCampaign( java.lang.String value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000001; campaign_ = value; onChanged(); return this; } /** *
     * Output only. The campaign to which this criterion belongs.
     * 
* * optional string campaign = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return This builder for chaining. */ public Builder clearCampaign() { bitField0_ = (bitField0_ & ~0x00000001); campaign_ = getDefaultInstance().getCampaign(); onChanged(); return this; } /** *
     * Output only. The campaign to which this criterion belongs.
     * 
* * optional string campaign = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @param value The bytes for campaign to set. * @return This builder for chaining. */ public Builder setCampaignBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); bitField0_ |= 0x00000001; campaign_ = value; onChanged(); return this; } private long criterionId_ ; /** *
     * Output only. The ID of the criterion to bid modify.
     * This field is ignored for mutates.
     * 
* * optional int64 criterion_id = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return Whether the criterionId field is set. */ @java.lang.Override public boolean hasCriterionId() { return ((bitField0_ & 0x00000002) != 0); } /** *
     * Output only. The ID of the criterion to bid modify.
     * This field is ignored for mutates.
     * 
* * optional int64 criterion_id = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The criterionId. */ @java.lang.Override public long getCriterionId() { return criterionId_; } /** *
     * Output only. The ID of the criterion to bid modify.
     * This field is ignored for mutates.
     * 
* * optional int64 criterion_id = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @param value The criterionId to set. * @return This builder for chaining. */ public Builder setCriterionId(long value) { bitField0_ |= 0x00000002; criterionId_ = value; onChanged(); return this; } /** *
     * Output only. The ID of the criterion to bid modify.
     * This field is ignored for mutates.
     * 
* * optional int64 criterion_id = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return This builder for chaining. */ public Builder clearCriterionId() { bitField0_ = (bitField0_ & ~0x00000002); criterionId_ = 0L; onChanged(); return this; } private double bidModifier_ ; /** *
     * The modifier for the bid when the criterion matches.
     * 
* * optional double bid_modifier = 8; * @return Whether the bidModifier field is set. */ @java.lang.Override public boolean hasBidModifier() { return ((bitField0_ & 0x00000004) != 0); } /** *
     * The modifier for the bid when the criterion matches.
     * 
* * optional double bid_modifier = 8; * @return The bidModifier. */ @java.lang.Override public double getBidModifier() { return bidModifier_; } /** *
     * The modifier for the bid when the criterion matches.
     * 
* * optional double bid_modifier = 8; * @param value The bidModifier to set. * @return This builder for chaining. */ public Builder setBidModifier(double value) { bitField0_ |= 0x00000004; bidModifier_ = value; onChanged(); return this; } /** *
     * The modifier for the bid when the criterion matches.
     * 
* * optional double bid_modifier = 8; * @return This builder for chaining. */ public Builder clearBidModifier() { bitField0_ = (bitField0_ & ~0x00000004); bidModifier_ = 0D; onChanged(); return this; } private com.google.protobuf.SingleFieldBuilderV3< com.google.ads.googleads.v10.common.InteractionTypeInfo, com.google.ads.googleads.v10.common.InteractionTypeInfo.Builder, com.google.ads.googleads.v10.common.InteractionTypeInfoOrBuilder> interactionTypeBuilder_; /** *
     * Immutable. Criterion for interaction type. Only supported for search campaigns.
     * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; * @return Whether the interactionType field is set. */ @java.lang.Override public boolean hasInteractionType() { return criterionCase_ == 5; } /** *
     * Immutable. Criterion for interaction type. Only supported for search campaigns.
     * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; * @return The interactionType. */ @java.lang.Override public com.google.ads.googleads.v10.common.InteractionTypeInfo getInteractionType() { if (interactionTypeBuilder_ == null) { if (criterionCase_ == 5) { return (com.google.ads.googleads.v10.common.InteractionTypeInfo) criterion_; } return com.google.ads.googleads.v10.common.InteractionTypeInfo.getDefaultInstance(); } else { if (criterionCase_ == 5) { return interactionTypeBuilder_.getMessage(); } return com.google.ads.googleads.v10.common.InteractionTypeInfo.getDefaultInstance(); } } /** *
     * Immutable. Criterion for interaction type. Only supported for search campaigns.
     * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; */ public Builder setInteractionType(com.google.ads.googleads.v10.common.InteractionTypeInfo value) { if (interactionTypeBuilder_ == null) { if (value == null) { throw new NullPointerException(); } criterion_ = value; onChanged(); } else { interactionTypeBuilder_.setMessage(value); } criterionCase_ = 5; return this; } /** *
     * Immutable. Criterion for interaction type. Only supported for search campaigns.
     * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; */ public Builder setInteractionType( com.google.ads.googleads.v10.common.InteractionTypeInfo.Builder builderForValue) { if (interactionTypeBuilder_ == null) { criterion_ = builderForValue.build(); onChanged(); } else { interactionTypeBuilder_.setMessage(builderForValue.build()); } criterionCase_ = 5; return this; } /** *
     * Immutable. Criterion for interaction type. Only supported for search campaigns.
     * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; */ public Builder mergeInteractionType(com.google.ads.googleads.v10.common.InteractionTypeInfo value) { if (interactionTypeBuilder_ == null) { if (criterionCase_ == 5 && criterion_ != com.google.ads.googleads.v10.common.InteractionTypeInfo.getDefaultInstance()) { criterion_ = com.google.ads.googleads.v10.common.InteractionTypeInfo.newBuilder((com.google.ads.googleads.v10.common.InteractionTypeInfo) criterion_) .mergeFrom(value).buildPartial(); } else { criterion_ = value; } onChanged(); } else { if (criterionCase_ == 5) { interactionTypeBuilder_.mergeFrom(value); } else { interactionTypeBuilder_.setMessage(value); } } criterionCase_ = 5; return this; } /** *
     * Immutable. Criterion for interaction type. Only supported for search campaigns.
     * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; */ public Builder clearInteractionType() { if (interactionTypeBuilder_ == null) { if (criterionCase_ == 5) { criterionCase_ = 0; criterion_ = null; onChanged(); } } else { if (criterionCase_ == 5) { criterionCase_ = 0; criterion_ = null; } interactionTypeBuilder_.clear(); } return this; } /** *
     * Immutable. Criterion for interaction type. Only supported for search campaigns.
     * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; */ public com.google.ads.googleads.v10.common.InteractionTypeInfo.Builder getInteractionTypeBuilder() { return getInteractionTypeFieldBuilder().getBuilder(); } /** *
     * Immutable. Criterion for interaction type. Only supported for search campaigns.
     * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; */ @java.lang.Override public com.google.ads.googleads.v10.common.InteractionTypeInfoOrBuilder getInteractionTypeOrBuilder() { if ((criterionCase_ == 5) && (interactionTypeBuilder_ != null)) { return interactionTypeBuilder_.getMessageOrBuilder(); } else { if (criterionCase_ == 5) { return (com.google.ads.googleads.v10.common.InteractionTypeInfo) criterion_; } return com.google.ads.googleads.v10.common.InteractionTypeInfo.getDefaultInstance(); } } /** *
     * Immutable. Criterion for interaction type. Only supported for search campaigns.
     * 
* * .google.ads.googleads.v10.common.InteractionTypeInfo interaction_type = 5 [(.google.api.field_behavior) = IMMUTABLE]; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.ads.googleads.v10.common.InteractionTypeInfo, com.google.ads.googleads.v10.common.InteractionTypeInfo.Builder, com.google.ads.googleads.v10.common.InteractionTypeInfoOrBuilder> getInteractionTypeFieldBuilder() { if (interactionTypeBuilder_ == null) { if (!(criterionCase_ == 5)) { criterion_ = com.google.ads.googleads.v10.common.InteractionTypeInfo.getDefaultInstance(); } interactionTypeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.ads.googleads.v10.common.InteractionTypeInfo, com.google.ads.googleads.v10.common.InteractionTypeInfo.Builder, com.google.ads.googleads.v10.common.InteractionTypeInfoOrBuilder>( (com.google.ads.googleads.v10.common.InteractionTypeInfo) criterion_, getParentForChildren(), isClean()); criterion_ = null; } criterionCase_ = 5; onChanged();; return interactionTypeBuilder_; } @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.resources.CampaignBidModifier) } // @@protoc_insertion_point(class_scope:google.ads.googleads.v10.resources.CampaignBidModifier) private static final com.google.ads.googleads.v10.resources.CampaignBidModifier DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.ads.googleads.v10.resources.CampaignBidModifier(); } public static com.google.ads.googleads.v10.resources.CampaignBidModifier getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public CampaignBidModifier 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.resources.CampaignBidModifier getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy