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

com.google.ads.googleads.v17.resources.CampaignDraft Maven / Gradle / Ivy

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

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

/**
 * 
 * A campaign draft.
 * 
* * Protobuf type {@code google.ads.googleads.v17.resources.CampaignDraft} */ public final class CampaignDraft extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:google.ads.googleads.v17.resources.CampaignDraft) CampaignDraftOrBuilder { private static final long serialVersionUID = 0L; // Use CampaignDraft.newBuilder() to construct. private CampaignDraft(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private CampaignDraft() { resourceName_ = ""; baseCampaign_ = ""; name_ = ""; draftCampaign_ = ""; status_ = 0; longRunningOperation_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new CampaignDraft(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.ads.googleads.v17.resources.CampaignDraftProto.internal_static_google_ads_googleads_v17_resources_CampaignDraft_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.ads.googleads.v17.resources.CampaignDraftProto.internal_static_google_ads_googleads_v17_resources_CampaignDraft_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.ads.googleads.v17.resources.CampaignDraft.class, com.google.ads.googleads.v17.resources.CampaignDraft.Builder.class); } private int bitField0_; public static final int RESOURCE_NAME_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object resourceName_ = ""; /** *
   * Immutable. The resource name of the campaign draft.
   * Campaign draft resource names have the form:
   *
   * `customers/{customer_id}/campaignDrafts/{base_campaign_id}~{draft_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 draft.
   * Campaign draft resource names have the form:
   *
   * `customers/{customer_id}/campaignDrafts/{base_campaign_id}~{draft_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 DRAFT_ID_FIELD_NUMBER = 9; private long draftId_ = 0L; /** *
   * Output only. The ID of the draft.
   *
   * This field is read-only.
   * 
* * optional int64 draft_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return Whether the draftId field is set. */ @java.lang.Override public boolean hasDraftId() { return ((bitField0_ & 0x00000001) != 0); } /** *
   * Output only. The ID of the draft.
   *
   * This field is read-only.
   * 
* * optional int64 draft_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The draftId. */ @java.lang.Override public long getDraftId() { return draftId_; } public static final int BASE_CAMPAIGN_FIELD_NUMBER = 10; @SuppressWarnings("serial") private volatile java.lang.Object baseCampaign_ = ""; /** *
   * Immutable. The base campaign to which the draft belongs.
   * 
* * optional string base_campaign = 10 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return Whether the baseCampaign field is set. */ @java.lang.Override public boolean hasBaseCampaign() { return ((bitField0_ & 0x00000002) != 0); } /** *
   * Immutable. The base campaign to which the draft belongs.
   * 
* * optional string base_campaign = 10 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return The baseCampaign. */ @java.lang.Override public java.lang.String getBaseCampaign() { java.lang.Object ref = baseCampaign_; 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(); baseCampaign_ = s; return s; } } /** *
   * Immutable. The base campaign to which the draft belongs.
   * 
* * optional string base_campaign = 10 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return The bytes for baseCampaign. */ @java.lang.Override public com.google.protobuf.ByteString getBaseCampaignBytes() { java.lang.Object ref = baseCampaign_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); baseCampaign_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int NAME_FIELD_NUMBER = 11; @SuppressWarnings("serial") private volatile java.lang.Object name_ = ""; /** *
   * The name of the campaign draft.
   *
   * This field is required and should not be empty when creating new
   * campaign drafts.
   *
   * It must not contain any null (code point 0x0), NL line feed
   * (code point 0xA) or carriage return (code point 0xD) characters.
   * 
* * optional string name = 11; * @return Whether the name field is set. */ @java.lang.Override public boolean hasName() { return ((bitField0_ & 0x00000004) != 0); } /** *
   * The name of the campaign draft.
   *
   * This field is required and should not be empty when creating new
   * campaign drafts.
   *
   * It must not contain any null (code point 0x0), NL line feed
   * (code point 0xA) or carriage return (code point 0xD) characters.
   * 
* * optional string name = 11; * @return The name. */ @java.lang.Override public java.lang.String getName() { java.lang.Object ref = name_; 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(); name_ = s; return s; } } /** *
   * The name of the campaign draft.
   *
   * This field is required and should not be empty when creating new
   * campaign drafts.
   *
   * It must not contain any null (code point 0x0), NL line feed
   * (code point 0xA) or carriage return (code point 0xD) characters.
   * 
* * optional string name = 11; * @return The bytes for name. */ @java.lang.Override public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); name_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int DRAFT_CAMPAIGN_FIELD_NUMBER = 12; @SuppressWarnings("serial") private volatile java.lang.Object draftCampaign_ = ""; /** *
   * Output only. Resource name of the Campaign that results from overlaying the
   * draft changes onto the base campaign.
   *
   * This field is read-only.
   * 
* * optional string draft_campaign = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return Whether the draftCampaign field is set. */ @java.lang.Override public boolean hasDraftCampaign() { return ((bitField0_ & 0x00000008) != 0); } /** *
   * Output only. Resource name of the Campaign that results from overlaying the
   * draft changes onto the base campaign.
   *
   * This field is read-only.
   * 
* * optional string draft_campaign = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return The draftCampaign. */ @java.lang.Override public java.lang.String getDraftCampaign() { java.lang.Object ref = draftCampaign_; 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(); draftCampaign_ = s; return s; } } /** *
   * Output only. Resource name of the Campaign that results from overlaying the
   * draft changes onto the base campaign.
   *
   * This field is read-only.
   * 
* * optional string draft_campaign = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return The bytes for draftCampaign. */ @java.lang.Override public com.google.protobuf.ByteString getDraftCampaignBytes() { java.lang.Object ref = draftCampaign_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); draftCampaign_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int STATUS_FIELD_NUMBER = 6; private int status_ = 0; /** *
   * Output only. The status of the campaign draft. This field is read-only.
   *
   * When a new campaign draft is added, the status defaults to PROPOSED.
   * 
* * .google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The enum numeric value on the wire for status. */ @java.lang.Override public int getStatusValue() { return status_; } /** *
   * Output only. The status of the campaign draft. This field is read-only.
   *
   * When a new campaign draft is added, the status defaults to PROPOSED.
   * 
* * .google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The status. */ @java.lang.Override public com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus getStatus() { com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus result = com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus.forNumber(status_); return result == null ? com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus.UNRECOGNIZED : result; } public static final int HAS_EXPERIMENT_RUNNING_FIELD_NUMBER = 13; private boolean hasExperimentRunning_ = false; /** *
   * Output only. Whether there is an experiment based on this draft currently
   * serving.
   * 
* * optional bool has_experiment_running = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return Whether the hasExperimentRunning field is set. */ @java.lang.Override public boolean hasHasExperimentRunning() { return ((bitField0_ & 0x00000010) != 0); } /** *
   * Output only. Whether there is an experiment based on this draft currently
   * serving.
   * 
* * optional bool has_experiment_running = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The hasExperimentRunning. */ @java.lang.Override public boolean getHasExperimentRunning() { return hasExperimentRunning_; } public static final int LONG_RUNNING_OPERATION_FIELD_NUMBER = 14; @SuppressWarnings("serial") private volatile java.lang.Object longRunningOperation_ = ""; /** *
   * Output only. The resource name of the long-running operation that can be
   * used to poll for completion of draft promotion. This is only set if the
   * draft promotion is in progress or finished.
   * 
* * optional string long_running_operation = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return Whether the longRunningOperation field is set. */ @java.lang.Override public boolean hasLongRunningOperation() { return ((bitField0_ & 0x00000020) != 0); } /** *
   * Output only. The resource name of the long-running operation that can be
   * used to poll for completion of draft promotion. This is only set if the
   * draft promotion is in progress or finished.
   * 
* * optional string long_running_operation = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The longRunningOperation. */ @java.lang.Override public java.lang.String getLongRunningOperation() { java.lang.Object ref = longRunningOperation_; 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(); longRunningOperation_ = s; return s; } } /** *
   * Output only. The resource name of the long-running operation that can be
   * used to poll for completion of draft promotion. This is only set if the
   * draft promotion is in progress or finished.
   * 
* * optional string long_running_operation = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The bytes for longRunningOperation. */ @java.lang.Override public com.google.protobuf.ByteString getLongRunningOperationBytes() { java.lang.Object ref = longRunningOperation_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); longRunningOperation_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } 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 (status_ != com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus.UNSPECIFIED.getNumber()) { output.writeEnum(6, status_); } if (((bitField0_ & 0x00000001) != 0)) { output.writeInt64(9, draftId_); } if (((bitField0_ & 0x00000002) != 0)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 10, baseCampaign_); } if (((bitField0_ & 0x00000004) != 0)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 11, name_); } if (((bitField0_ & 0x00000008) != 0)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 12, draftCampaign_); } if (((bitField0_ & 0x00000010) != 0)) { output.writeBool(13, hasExperimentRunning_); } if (((bitField0_ & 0x00000020) != 0)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 14, longRunningOperation_); } 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 (status_ != com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus.UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream .computeEnumSize(6, status_); } if (((bitField0_ & 0x00000001) != 0)) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(9, draftId_); } if (((bitField0_ & 0x00000002) != 0)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(10, baseCampaign_); } if (((bitField0_ & 0x00000004) != 0)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(11, name_); } if (((bitField0_ & 0x00000008) != 0)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(12, draftCampaign_); } if (((bitField0_ & 0x00000010) != 0)) { size += com.google.protobuf.CodedOutputStream .computeBoolSize(13, hasExperimentRunning_); } if (((bitField0_ & 0x00000020) != 0)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(14, longRunningOperation_); } 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.resources.CampaignDraft)) { return super.equals(obj); } com.google.ads.googleads.v17.resources.CampaignDraft other = (com.google.ads.googleads.v17.resources.CampaignDraft) obj; if (!getResourceName() .equals(other.getResourceName())) return false; if (hasDraftId() != other.hasDraftId()) return false; if (hasDraftId()) { if (getDraftId() != other.getDraftId()) return false; } if (hasBaseCampaign() != other.hasBaseCampaign()) return false; if (hasBaseCampaign()) { if (!getBaseCampaign() .equals(other.getBaseCampaign())) return false; } if (hasName() != other.hasName()) return false; if (hasName()) { if (!getName() .equals(other.getName())) return false; } if (hasDraftCampaign() != other.hasDraftCampaign()) return false; if (hasDraftCampaign()) { if (!getDraftCampaign() .equals(other.getDraftCampaign())) return false; } if (status_ != other.status_) return false; if (hasHasExperimentRunning() != other.hasHasExperimentRunning()) return false; if (hasHasExperimentRunning()) { if (getHasExperimentRunning() != other.getHasExperimentRunning()) return false; } if (hasLongRunningOperation() != other.hasLongRunningOperation()) return false; if (hasLongRunningOperation()) { if (!getLongRunningOperation() .equals(other.getLongRunningOperation())) return false; } if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + RESOURCE_NAME_FIELD_NUMBER; hash = (53 * hash) + getResourceName().hashCode(); if (hasDraftId()) { hash = (37 * hash) + DRAFT_ID_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getDraftId()); } if (hasBaseCampaign()) { hash = (37 * hash) + BASE_CAMPAIGN_FIELD_NUMBER; hash = (53 * hash) + getBaseCampaign().hashCode(); } if (hasName()) { hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); } if (hasDraftCampaign()) { hash = (37 * hash) + DRAFT_CAMPAIGN_FIELD_NUMBER; hash = (53 * hash) + getDraftCampaign().hashCode(); } hash = (37 * hash) + STATUS_FIELD_NUMBER; hash = (53 * hash) + status_; if (hasHasExperimentRunning()) { hash = (37 * hash) + HAS_EXPERIMENT_RUNNING_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean( getHasExperimentRunning()); } if (hasLongRunningOperation()) { hash = (37 * hash) + LONG_RUNNING_OPERATION_FIELD_NUMBER; hash = (53 * hash) + getLongRunningOperation().hashCode(); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static com.google.ads.googleads.v17.resources.CampaignDraft parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.ads.googleads.v17.resources.CampaignDraft 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.resources.CampaignDraft parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.ads.googleads.v17.resources.CampaignDraft 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.resources.CampaignDraft parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static com.google.ads.googleads.v17.resources.CampaignDraft 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.resources.CampaignDraft parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static com.google.ads.googleads.v17.resources.CampaignDraft 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.resources.CampaignDraft parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static com.google.ads.googleads.v17.resources.CampaignDraft 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.resources.CampaignDraft 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.resources.CampaignDraft 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.resources.CampaignDraft prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } @java.lang.Override public Builder toBuilder() { return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } @java.lang.Override protected Builder newBuilderForType( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** *
   * A campaign draft.
   * 
* * Protobuf type {@code google.ads.googleads.v17.resources.CampaignDraft} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:google.ads.googleads.v17.resources.CampaignDraft) com.google.ads.googleads.v17.resources.CampaignDraftOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.ads.googleads.v17.resources.CampaignDraftProto.internal_static_google_ads_googleads_v17_resources_CampaignDraft_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.ads.googleads.v17.resources.CampaignDraftProto.internal_static_google_ads_googleads_v17_resources_CampaignDraft_fieldAccessorTable .ensureFieldAccessorsInitialized( com.google.ads.googleads.v17.resources.CampaignDraft.class, com.google.ads.googleads.v17.resources.CampaignDraft.Builder.class); } // Construct using com.google.ads.googleads.v17.resources.CampaignDraft.newBuilder() private Builder() { } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; resourceName_ = ""; draftId_ = 0L; baseCampaign_ = ""; name_ = ""; draftCampaign_ = ""; status_ = 0; hasExperimentRunning_ = false; longRunningOperation_ = ""; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.ads.googleads.v17.resources.CampaignDraftProto.internal_static_google_ads_googleads_v17_resources_CampaignDraft_descriptor; } @java.lang.Override public com.google.ads.googleads.v17.resources.CampaignDraft getDefaultInstanceForType() { return com.google.ads.googleads.v17.resources.CampaignDraft.getDefaultInstance(); } @java.lang.Override public com.google.ads.googleads.v17.resources.CampaignDraft build() { com.google.ads.googleads.v17.resources.CampaignDraft result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public com.google.ads.googleads.v17.resources.CampaignDraft buildPartial() { com.google.ads.googleads.v17.resources.CampaignDraft result = new com.google.ads.googleads.v17.resources.CampaignDraft(this); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartial0(com.google.ads.googleads.v17.resources.CampaignDraft result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.resourceName_ = resourceName_; } int to_bitField0_ = 0; if (((from_bitField0_ & 0x00000002) != 0)) { result.draftId_ = draftId_; to_bitField0_ |= 0x00000001; } if (((from_bitField0_ & 0x00000004) != 0)) { result.baseCampaign_ = baseCampaign_; to_bitField0_ |= 0x00000002; } if (((from_bitField0_ & 0x00000008) != 0)) { result.name_ = name_; to_bitField0_ |= 0x00000004; } if (((from_bitField0_ & 0x00000010) != 0)) { result.draftCampaign_ = draftCampaign_; to_bitField0_ |= 0x00000008; } if (((from_bitField0_ & 0x00000020) != 0)) { result.status_ = status_; } if (((from_bitField0_ & 0x00000040) != 0)) { result.hasExperimentRunning_ = hasExperimentRunning_; to_bitField0_ |= 0x00000010; } if (((from_bitField0_ & 0x00000080) != 0)) { result.longRunningOperation_ = longRunningOperation_; to_bitField0_ |= 0x00000020; } 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.resources.CampaignDraft) { return mergeFrom((com.google.ads.googleads.v17.resources.CampaignDraft)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(com.google.ads.googleads.v17.resources.CampaignDraft other) { if (other == com.google.ads.googleads.v17.resources.CampaignDraft.getDefaultInstance()) return this; if (!other.getResourceName().isEmpty()) { resourceName_ = other.resourceName_; bitField0_ |= 0x00000001; onChanged(); } if (other.hasDraftId()) { setDraftId(other.getDraftId()); } if (other.hasBaseCampaign()) { baseCampaign_ = other.baseCampaign_; bitField0_ |= 0x00000004; onChanged(); } if (other.hasName()) { name_ = other.name_; bitField0_ |= 0x00000008; onChanged(); } if (other.hasDraftCampaign()) { draftCampaign_ = other.draftCampaign_; bitField0_ |= 0x00000010; onChanged(); } if (other.status_ != 0) { setStatusValue(other.getStatusValue()); } if (other.hasHasExperimentRunning()) { setHasExperimentRunning(other.getHasExperimentRunning()); } if (other.hasLongRunningOperation()) { longRunningOperation_ = other.longRunningOperation_; bitField0_ |= 0x00000080; onChanged(); } this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @java.lang.Override public final boolean isInitialized() { return true; } @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { resourceName_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 48: { status_ = input.readEnum(); bitField0_ |= 0x00000020; break; } // case 48 case 72: { draftId_ = input.readInt64(); bitField0_ |= 0x00000002; break; } // case 72 case 82: { baseCampaign_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000004; break; } // case 82 case 90: { name_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000008; break; } // case 90 case 98: { draftCampaign_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000010; break; } // case 98 case 104: { hasExperimentRunning_ = input.readBool(); bitField0_ |= 0x00000040; break; } // case 104 case 114: { longRunningOperation_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000080; break; } // case 114 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 resourceName_ = ""; /** *
     * Immutable. The resource name of the campaign draft.
     * Campaign draft resource names have the form:
     *
     * `customers/{customer_id}/campaignDrafts/{base_campaign_id}~{draft_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 draft.
     * Campaign draft resource names have the form:
     *
     * `customers/{customer_id}/campaignDrafts/{base_campaign_id}~{draft_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 draft.
     * Campaign draft resource names have the form:
     *
     * `customers/{customer_id}/campaignDrafts/{base_campaign_id}~{draft_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; bitField0_ |= 0x00000001; onChanged(); return this; } /** *
     * Immutable. The resource name of the campaign draft.
     * Campaign draft resource names have the form:
     *
     * `customers/{customer_id}/campaignDrafts/{base_campaign_id}~{draft_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(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** *
     * Immutable. The resource name of the campaign draft.
     * Campaign draft resource names have the form:
     *
     * `customers/{customer_id}/campaignDrafts/{base_campaign_id}~{draft_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; bitField0_ |= 0x00000001; onChanged(); return this; } private long draftId_ ; /** *
     * Output only. The ID of the draft.
     *
     * This field is read-only.
     * 
* * optional int64 draft_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return Whether the draftId field is set. */ @java.lang.Override public boolean hasDraftId() { return ((bitField0_ & 0x00000002) != 0); } /** *
     * Output only. The ID of the draft.
     *
     * This field is read-only.
     * 
* * optional int64 draft_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The draftId. */ @java.lang.Override public long getDraftId() { return draftId_; } /** *
     * Output only. The ID of the draft.
     *
     * This field is read-only.
     * 
* * optional int64 draft_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @param value The draftId to set. * @return This builder for chaining. */ public Builder setDraftId(long value) { draftId_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** *
     * Output only. The ID of the draft.
     *
     * This field is read-only.
     * 
* * optional int64 draft_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return This builder for chaining. */ public Builder clearDraftId() { bitField0_ = (bitField0_ & ~0x00000002); draftId_ = 0L; onChanged(); return this; } private java.lang.Object baseCampaign_ = ""; /** *
     * Immutable. The base campaign to which the draft belongs.
     * 
* * optional string base_campaign = 10 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return Whether the baseCampaign field is set. */ public boolean hasBaseCampaign() { return ((bitField0_ & 0x00000004) != 0); } /** *
     * Immutable. The base campaign to which the draft belongs.
     * 
* * optional string base_campaign = 10 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return The baseCampaign. */ public java.lang.String getBaseCampaign() { java.lang.Object ref = baseCampaign_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); baseCampaign_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     * Immutable. The base campaign to which the draft belongs.
     * 
* * optional string base_campaign = 10 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return The bytes for baseCampaign. */ public com.google.protobuf.ByteString getBaseCampaignBytes() { java.lang.Object ref = baseCampaign_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); baseCampaign_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     * Immutable. The base campaign to which the draft belongs.
     * 
* * optional string base_campaign = 10 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @param value The baseCampaign to set. * @return This builder for chaining. */ public Builder setBaseCampaign( java.lang.String value) { if (value == null) { throw new NullPointerException(); } baseCampaign_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } /** *
     * Immutable. The base campaign to which the draft belongs.
     * 
* * optional string base_campaign = 10 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @return This builder for chaining. */ public Builder clearBaseCampaign() { baseCampaign_ = getDefaultInstance().getBaseCampaign(); bitField0_ = (bitField0_ & ~0x00000004); onChanged(); return this; } /** *
     * Immutable. The base campaign to which the draft belongs.
     * 
* * optional string base_campaign = 10 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... } * @param value The bytes for baseCampaign to set. * @return This builder for chaining. */ public Builder setBaseCampaignBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); baseCampaign_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } private java.lang.Object name_ = ""; /** *
     * The name of the campaign draft.
     *
     * This field is required and should not be empty when creating new
     * campaign drafts.
     *
     * It must not contain any null (code point 0x0), NL line feed
     * (code point 0xA) or carriage return (code point 0xD) characters.
     * 
* * optional string name = 11; * @return Whether the name field is set. */ public boolean hasName() { return ((bitField0_ & 0x00000008) != 0); } /** *
     * The name of the campaign draft.
     *
     * This field is required and should not be empty when creating new
     * campaign drafts.
     *
     * It must not contain any null (code point 0x0), NL line feed
     * (code point 0xA) or carriage return (code point 0xD) characters.
     * 
* * optional string name = 11; * @return The name. */ public java.lang.String getName() { java.lang.Object ref = name_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); name_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     * The name of the campaign draft.
     *
     * This field is required and should not be empty when creating new
     * campaign drafts.
     *
     * It must not contain any null (code point 0x0), NL line feed
     * (code point 0xA) or carriage return (code point 0xD) characters.
     * 
* * optional string name = 11; * @return The bytes for name. */ public com.google.protobuf.ByteString getNameBytes() { java.lang.Object ref = name_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); name_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     * The name of the campaign draft.
     *
     * This field is required and should not be empty when creating new
     * campaign drafts.
     *
     * It must not contain any null (code point 0x0), NL line feed
     * (code point 0xA) or carriage return (code point 0xD) characters.
     * 
* * optional string name = 11; * @param value The name to set. * @return This builder for chaining. */ public Builder setName( java.lang.String value) { if (value == null) { throw new NullPointerException(); } name_ = value; bitField0_ |= 0x00000008; onChanged(); return this; } /** *
     * The name of the campaign draft.
     *
     * This field is required and should not be empty when creating new
     * campaign drafts.
     *
     * It must not contain any null (code point 0x0), NL line feed
     * (code point 0xA) or carriage return (code point 0xD) characters.
     * 
* * optional string name = 11; * @return This builder for chaining. */ public Builder clearName() { name_ = getDefaultInstance().getName(); bitField0_ = (bitField0_ & ~0x00000008); onChanged(); return this; } /** *
     * The name of the campaign draft.
     *
     * This field is required and should not be empty when creating new
     * campaign drafts.
     *
     * It must not contain any null (code point 0x0), NL line feed
     * (code point 0xA) or carriage return (code point 0xD) characters.
     * 
* * optional string name = 11; * @param value The bytes for name to set. * @return This builder for chaining. */ public Builder setNameBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); name_ = value; bitField0_ |= 0x00000008; onChanged(); return this; } private java.lang.Object draftCampaign_ = ""; /** *
     * Output only. Resource name of the Campaign that results from overlaying the
     * draft changes onto the base campaign.
     *
     * This field is read-only.
     * 
* * optional string draft_campaign = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return Whether the draftCampaign field is set. */ public boolean hasDraftCampaign() { return ((bitField0_ & 0x00000010) != 0); } /** *
     * Output only. Resource name of the Campaign that results from overlaying the
     * draft changes onto the base campaign.
     *
     * This field is read-only.
     * 
* * optional string draft_campaign = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return The draftCampaign. */ public java.lang.String getDraftCampaign() { java.lang.Object ref = draftCampaign_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); draftCampaign_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     * Output only. Resource name of the Campaign that results from overlaying the
     * draft changes onto the base campaign.
     *
     * This field is read-only.
     * 
* * optional string draft_campaign = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return The bytes for draftCampaign. */ public com.google.protobuf.ByteString getDraftCampaignBytes() { java.lang.Object ref = draftCampaign_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); draftCampaign_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     * Output only. Resource name of the Campaign that results from overlaying the
     * draft changes onto the base campaign.
     *
     * This field is read-only.
     * 
* * optional string draft_campaign = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @param value The draftCampaign to set. * @return This builder for chaining. */ public Builder setDraftCampaign( java.lang.String value) { if (value == null) { throw new NullPointerException(); } draftCampaign_ = value; bitField0_ |= 0x00000010; onChanged(); return this; } /** *
     * Output only. Resource name of the Campaign that results from overlaying the
     * draft changes onto the base campaign.
     *
     * This field is read-only.
     * 
* * optional string draft_campaign = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @return This builder for chaining. */ public Builder clearDraftCampaign() { draftCampaign_ = getDefaultInstance().getDraftCampaign(); bitField0_ = (bitField0_ & ~0x00000010); onChanged(); return this; } /** *
     * Output only. Resource name of the Campaign that results from overlaying the
     * draft changes onto the base campaign.
     *
     * This field is read-only.
     * 
* * optional string draft_campaign = 12 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } * @param value The bytes for draftCampaign to set. * @return This builder for chaining. */ public Builder setDraftCampaignBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); draftCampaign_ = value; bitField0_ |= 0x00000010; onChanged(); return this; } private int status_ = 0; /** *
     * Output only. The status of the campaign draft. This field is read-only.
     *
     * When a new campaign draft is added, the status defaults to PROPOSED.
     * 
* * .google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The enum numeric value on the wire for status. */ @java.lang.Override public int getStatusValue() { return status_; } /** *
     * Output only. The status of the campaign draft. This field is read-only.
     *
     * When a new campaign draft is added, the status defaults to PROPOSED.
     * 
* * .google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @param value The enum numeric value on the wire for status to set. * @return This builder for chaining. */ public Builder setStatusValue(int value) { status_ = value; bitField0_ |= 0x00000020; onChanged(); return this; } /** *
     * Output only. The status of the campaign draft. This field is read-only.
     *
     * When a new campaign draft is added, the status defaults to PROPOSED.
     * 
* * .google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The status. */ @java.lang.Override public com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus getStatus() { com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus result = com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus.forNumber(status_); return result == null ? com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus.UNRECOGNIZED : result; } /** *
     * Output only. The status of the campaign draft. This field is read-only.
     *
     * When a new campaign draft is added, the status defaults to PROPOSED.
     * 
* * .google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @param value The status to set. * @return This builder for chaining. */ public Builder setStatus(com.google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000020; status_ = value.getNumber(); onChanged(); return this; } /** *
     * Output only. The status of the campaign draft. This field is read-only.
     *
     * When a new campaign draft is added, the status defaults to PROPOSED.
     * 
* * .google.ads.googleads.v17.enums.CampaignDraftStatusEnum.CampaignDraftStatus status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return This builder for chaining. */ public Builder clearStatus() { bitField0_ = (bitField0_ & ~0x00000020); status_ = 0; onChanged(); return this; } private boolean hasExperimentRunning_ ; /** *
     * Output only. Whether there is an experiment based on this draft currently
     * serving.
     * 
* * optional bool has_experiment_running = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return Whether the hasExperimentRunning field is set. */ @java.lang.Override public boolean hasHasExperimentRunning() { return ((bitField0_ & 0x00000040) != 0); } /** *
     * Output only. Whether there is an experiment based on this draft currently
     * serving.
     * 
* * optional bool has_experiment_running = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The hasExperimentRunning. */ @java.lang.Override public boolean getHasExperimentRunning() { return hasExperimentRunning_; } /** *
     * Output only. Whether there is an experiment based on this draft currently
     * serving.
     * 
* * optional bool has_experiment_running = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @param value The hasExperimentRunning to set. * @return This builder for chaining. */ public Builder setHasExperimentRunning(boolean value) { hasExperimentRunning_ = value; bitField0_ |= 0x00000040; onChanged(); return this; } /** *
     * Output only. Whether there is an experiment based on this draft currently
     * serving.
     * 
* * optional bool has_experiment_running = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return This builder for chaining. */ public Builder clearHasExperimentRunning() { bitField0_ = (bitField0_ & ~0x00000040); hasExperimentRunning_ = false; onChanged(); return this; } private java.lang.Object longRunningOperation_ = ""; /** *
     * Output only. The resource name of the long-running operation that can be
     * used to poll for completion of draft promotion. This is only set if the
     * draft promotion is in progress or finished.
     * 
* * optional string long_running_operation = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return Whether the longRunningOperation field is set. */ public boolean hasLongRunningOperation() { return ((bitField0_ & 0x00000080) != 0); } /** *
     * Output only. The resource name of the long-running operation that can be
     * used to poll for completion of draft promotion. This is only set if the
     * draft promotion is in progress or finished.
     * 
* * optional string long_running_operation = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The longRunningOperation. */ public java.lang.String getLongRunningOperation() { java.lang.Object ref = longRunningOperation_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); longRunningOperation_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     * Output only. The resource name of the long-running operation that can be
     * used to poll for completion of draft promotion. This is only set if the
     * draft promotion is in progress or finished.
     * 
* * optional string long_running_operation = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return The bytes for longRunningOperation. */ public com.google.protobuf.ByteString getLongRunningOperationBytes() { java.lang.Object ref = longRunningOperation_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); longRunningOperation_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     * Output only. The resource name of the long-running operation that can be
     * used to poll for completion of draft promotion. This is only set if the
     * draft promotion is in progress or finished.
     * 
* * optional string long_running_operation = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @param value The longRunningOperation to set. * @return This builder for chaining. */ public Builder setLongRunningOperation( java.lang.String value) { if (value == null) { throw new NullPointerException(); } longRunningOperation_ = value; bitField0_ |= 0x00000080; onChanged(); return this; } /** *
     * Output only. The resource name of the long-running operation that can be
     * used to poll for completion of draft promotion. This is only set if the
     * draft promotion is in progress or finished.
     * 
* * optional string long_running_operation = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @return This builder for chaining. */ public Builder clearLongRunningOperation() { longRunningOperation_ = getDefaultInstance().getLongRunningOperation(); bitField0_ = (bitField0_ & ~0x00000080); onChanged(); return this; } /** *
     * Output only. The resource name of the long-running operation that can be
     * used to poll for completion of draft promotion. This is only set if the
     * draft promotion is in progress or finished.
     * 
* * optional string long_running_operation = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; * @param value The bytes for longRunningOperation to set. * @return This builder for chaining. */ public Builder setLongRunningOperationBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); longRunningOperation_ = value; bitField0_ |= 0x00000080; onChanged(); return this; } @java.lang.Override public final Builder setUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } // @@protoc_insertion_point(builder_scope:google.ads.googleads.v17.resources.CampaignDraft) } // @@protoc_insertion_point(class_scope:google.ads.googleads.v17.resources.CampaignDraft) private static final com.google.ads.googleads.v17.resources.CampaignDraft DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new com.google.ads.googleads.v17.resources.CampaignDraft(); } public static com.google.ads.googleads.v17.resources.CampaignDraft getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public CampaignDraft 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.resources.CampaignDraft getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy