Class Experiment

java.lang.Object
com.google.protobuf.AbstractMessageLite
com.google.protobuf.AbstractMessage
com.google.protobuf.GeneratedMessageV3
com.google.ads.googleads.v18.resources.Experiment
All Implemented Interfaces:
ExperimentOrBuilder, com.google.protobuf.Message, com.google.protobuf.MessageLite, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Serializable

public final class Experiment extends com.google.protobuf.GeneratedMessageV3 implements ExperimentOrBuilder
 A Google ads experiment for users to experiment changes on multiple
 campaigns, compare the performance, and apply the effective changes.
 
Protobuf type google.ads.googleads.v18.resources.Experiment
See Also:
  • Field Details

    • RESOURCE_NAME_FIELD_NUMBER

      public static final int RESOURCE_NAME_FIELD_NUMBER
      See Also:
    • EXPERIMENT_ID_FIELD_NUMBER

      public static final int EXPERIMENT_ID_FIELD_NUMBER
      See Also:
    • NAME_FIELD_NUMBER

      public static final int NAME_FIELD_NUMBER
      See Also:
    • DESCRIPTION_FIELD_NUMBER

      public static final int DESCRIPTION_FIELD_NUMBER
      See Also:
    • SUFFIX_FIELD_NUMBER

      public static final int SUFFIX_FIELD_NUMBER
      See Also:
    • TYPE_FIELD_NUMBER

      public static final int TYPE_FIELD_NUMBER
      See Also:
    • STATUS_FIELD_NUMBER

      public static final int STATUS_FIELD_NUMBER
      See Also:
    • START_DATE_FIELD_NUMBER

      public static final int START_DATE_FIELD_NUMBER
      See Also:
    • END_DATE_FIELD_NUMBER

      public static final int END_DATE_FIELD_NUMBER
      See Also:
    • GOALS_FIELD_NUMBER

      public static final int GOALS_FIELD_NUMBER
      See Also:
    • LONG_RUNNING_OPERATION_FIELD_NUMBER

      public static final int LONG_RUNNING_OPERATION_FIELD_NUMBER
      See Also:
    • PROMOTE_STATUS_FIELD_NUMBER

      public static final int PROMOTE_STATUS_FIELD_NUMBER
      See Also:
    • SYNC_ENABLED_FIELD_NUMBER

      public static final int SYNC_ENABLED_FIELD_NUMBER
      See Also:
  • Method Details

    • newInstance

      protected Object newInstance(com.google.protobuf.GeneratedMessageV3.UnusedPrivateParameter unused)
      Overrides:
      newInstance in class com.google.protobuf.GeneratedMessageV3
    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessageV3
    • getResourceName

      public String getResourceName()
       Immutable. The resource name of the experiment.
       Experiment resource names have the form:
      
       `customers/{customer_id}/experiments/{experiment_id}`
       
      string resource_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... }
      Specified by:
      getResourceName in interface ExperimentOrBuilder
      Returns:
      The resourceName.
    • getResourceNameBytes

      public com.google.protobuf.ByteString getResourceNameBytes()
       Immutable. The resource name of the experiment.
       Experiment resource names have the form:
      
       `customers/{customer_id}/experiments/{experiment_id}`
       
      string resource_name = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { ... }
      Specified by:
      getResourceNameBytes in interface ExperimentOrBuilder
      Returns:
      The bytes for resourceName.
    • hasExperimentId

      public boolean hasExperimentId()
       Output only. The ID of the experiment. Read only.
       
      optional int64 experiment_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      hasExperimentId in interface ExperimentOrBuilder
      Returns:
      Whether the experimentId field is set.
    • getExperimentId

      public long getExperimentId()
       Output only. The ID of the experiment. Read only.
       
      optional int64 experiment_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getExperimentId in interface ExperimentOrBuilder
      Returns:
      The experimentId.
    • getName

      public String getName()
       Required. The name of the experiment. It must have a minimum length of 1
       and maximum length of 1024. It must be unique under a customer.
       
      string name = 10 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getName in interface ExperimentOrBuilder
      Returns:
      The name.
    • getNameBytes

      public com.google.protobuf.ByteString getNameBytes()
       Required. The name of the experiment. It must have a minimum length of 1
       and maximum length of 1024. It must be unique under a customer.
       
      string name = 10 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getNameBytes in interface ExperimentOrBuilder
      Returns:
      The bytes for name.
    • getDescription

      public String getDescription()
       The description of the experiment. It must have a minimum length of 1 and
       maximum length of 2048.
       
      string description = 11;
      Specified by:
      getDescription in interface ExperimentOrBuilder
      Returns:
      The description.
    • getDescriptionBytes

      public com.google.protobuf.ByteString getDescriptionBytes()
       The description of the experiment. It must have a minimum length of 1 and
       maximum length of 2048.
       
      string description = 11;
      Specified by:
      getDescriptionBytes in interface ExperimentOrBuilder
      Returns:
      The bytes for description.
    • getSuffix

      public String getSuffix()
       For system managed experiments, the advertiser must provide a suffix during
       construction, in the setup stage before moving to initiated. The suffix
       will be appended to the in-design and experiment campaign names so that the
       name is base campaign name + suffix.
       
      string suffix = 12;
      Specified by:
      getSuffix in interface ExperimentOrBuilder
      Returns:
      The suffix.
    • getSuffixBytes

      public com.google.protobuf.ByteString getSuffixBytes()
       For system managed experiments, the advertiser must provide a suffix during
       construction, in the setup stage before moving to initiated. The suffix
       will be appended to the in-design and experiment campaign names so that the
       name is base campaign name + suffix.
       
      string suffix = 12;
      Specified by:
      getSuffixBytes in interface ExperimentOrBuilder
      Returns:
      The bytes for suffix.
    • getTypeValue

      public int getTypeValue()
       Required. The product/feature that uses this experiment.
       
      .google.ads.googleads.v18.enums.ExperimentTypeEnum.ExperimentType type = 13 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getTypeValue in interface ExperimentOrBuilder
      Returns:
      The enum numeric value on the wire for type.
    • getType

       Required. The product/feature that uses this experiment.
       
      .google.ads.googleads.v18.enums.ExperimentTypeEnum.ExperimentType type = 13 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getType in interface ExperimentOrBuilder
      Returns:
      The type.
    • getStatusValue

      public int getStatusValue()
       The Advertiser-chosen status of this experiment.
       
      .google.ads.googleads.v18.enums.ExperimentStatusEnum.ExperimentStatus status = 14;
      Specified by:
      getStatusValue in interface ExperimentOrBuilder
      Returns:
      The enum numeric value on the wire for status.
    • getStatus

       The Advertiser-chosen status of this experiment.
       
      .google.ads.googleads.v18.enums.ExperimentStatusEnum.ExperimentStatus status = 14;
      Specified by:
      getStatus in interface ExperimentOrBuilder
      Returns:
      The status.
    • hasStartDate

      public boolean hasStartDate()
       Date when the experiment starts. By default, the experiment starts
       now or on the campaign's start date, whichever is later. If this field is
       set, then the experiment starts at the beginning of the specified date in
       the customer's time zone.
      
       Format: YYYY-MM-DD
       Example: 2019-03-14
       
      optional string start_date = 15;
      Specified by:
      hasStartDate in interface ExperimentOrBuilder
      Returns:
      Whether the startDate field is set.
    • getStartDate

      public String getStartDate()
       Date when the experiment starts. By default, the experiment starts
       now or on the campaign's start date, whichever is later. If this field is
       set, then the experiment starts at the beginning of the specified date in
       the customer's time zone.
      
       Format: YYYY-MM-DD
       Example: 2019-03-14
       
      optional string start_date = 15;
      Specified by:
      getStartDate in interface ExperimentOrBuilder
      Returns:
      The startDate.
    • getStartDateBytes

      public com.google.protobuf.ByteString getStartDateBytes()
       Date when the experiment starts. By default, the experiment starts
       now or on the campaign's start date, whichever is later. If this field is
       set, then the experiment starts at the beginning of the specified date in
       the customer's time zone.
      
       Format: YYYY-MM-DD
       Example: 2019-03-14
       
      optional string start_date = 15;
      Specified by:
      getStartDateBytes in interface ExperimentOrBuilder
      Returns:
      The bytes for startDate.
    • hasEndDate

      public boolean hasEndDate()
       Date when the experiment ends. By default, the experiment ends on
       the campaign's end date. If this field is set, then the experiment ends at
       the end of the specified date in the customer's time zone.
      
       Format: YYYY-MM-DD
       Example: 2019-04-18
       
      optional string end_date = 16;
      Specified by:
      hasEndDate in interface ExperimentOrBuilder
      Returns:
      Whether the endDate field is set.
    • getEndDate

      public String getEndDate()
       Date when the experiment ends. By default, the experiment ends on
       the campaign's end date. If this field is set, then the experiment ends at
       the end of the specified date in the customer's time zone.
      
       Format: YYYY-MM-DD
       Example: 2019-04-18
       
      optional string end_date = 16;
      Specified by:
      getEndDate in interface ExperimentOrBuilder
      Returns:
      The endDate.
    • getEndDateBytes

      public com.google.protobuf.ByteString getEndDateBytes()
       Date when the experiment ends. By default, the experiment ends on
       the campaign's end date. If this field is set, then the experiment ends at
       the end of the specified date in the customer's time zone.
      
       Format: YYYY-MM-DD
       Example: 2019-04-18
       
      optional string end_date = 16;
      Specified by:
      getEndDateBytes in interface ExperimentOrBuilder
      Returns:
      The bytes for endDate.
    • getGoalsList

      public List<MetricGoal> getGoalsList()
       The goals of this experiment.
       
      repeated .google.ads.googleads.v18.common.MetricGoal goals = 17;
      Specified by:
      getGoalsList in interface ExperimentOrBuilder
    • getGoalsOrBuilderList

      public List<? extends MetricGoalOrBuilder> getGoalsOrBuilderList()
       The goals of this experiment.
       
      repeated .google.ads.googleads.v18.common.MetricGoal goals = 17;
      Specified by:
      getGoalsOrBuilderList in interface ExperimentOrBuilder
    • getGoalsCount

      public int getGoalsCount()
       The goals of this experiment.
       
      repeated .google.ads.googleads.v18.common.MetricGoal goals = 17;
      Specified by:
      getGoalsCount in interface ExperimentOrBuilder
    • getGoals

      public MetricGoal getGoals(int index)
       The goals of this experiment.
       
      repeated .google.ads.googleads.v18.common.MetricGoal goals = 17;
      Specified by:
      getGoals in interface ExperimentOrBuilder
    • getGoalsOrBuilder

      public MetricGoalOrBuilder getGoalsOrBuilder(int index)
       The goals of this experiment.
       
      repeated .google.ads.googleads.v18.common.MetricGoal goals = 17;
      Specified by:
      getGoalsOrBuilder in interface ExperimentOrBuilder
    • hasLongRunningOperation

      public boolean hasLongRunningOperation()
       Output only. The resource name of the long-running operation that can be
       used to poll for completion of experiment schedule or promote. The most
       recent long running operation is returned.
       
      optional string long_running_operation = 18 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      hasLongRunningOperation in interface ExperimentOrBuilder
      Returns:
      Whether the longRunningOperation field is set.
    • getLongRunningOperation

      public String getLongRunningOperation()
       Output only. The resource name of the long-running operation that can be
       used to poll for completion of experiment schedule or promote. The most
       recent long running operation is returned.
       
      optional string long_running_operation = 18 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getLongRunningOperation in interface ExperimentOrBuilder
      Returns:
      The longRunningOperation.
    • getLongRunningOperationBytes

      public com.google.protobuf.ByteString getLongRunningOperationBytes()
       Output only. The resource name of the long-running operation that can be
       used to poll for completion of experiment schedule or promote. The most
       recent long running operation is returned.
       
      optional string long_running_operation = 18 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getLongRunningOperationBytes in interface ExperimentOrBuilder
      Returns:
      The bytes for longRunningOperation.
    • getPromoteStatusValue

      public int getPromoteStatusValue()
       Output only. The status of the experiment promotion process.
       
      .google.ads.googleads.v18.enums.AsyncActionStatusEnum.AsyncActionStatus promote_status = 19 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getPromoteStatusValue in interface ExperimentOrBuilder
      Returns:
      The enum numeric value on the wire for promoteStatus.
    • getPromoteStatus

      public AsyncActionStatusEnum.AsyncActionStatus getPromoteStatus()
       Output only. The status of the experiment promotion process.
       
      .google.ads.googleads.v18.enums.AsyncActionStatusEnum.AsyncActionStatus promote_status = 19 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getPromoteStatus in interface ExperimentOrBuilder
      Returns:
      The promoteStatus.
    • hasSyncEnabled

      public boolean hasSyncEnabled()
       Immutable. Set to true if changes to base campaigns should be synced to the
       trial campaigns. Any changes made directly to trial campaigns will be
       preserved. This field can only be set when the experiment is being created.
       
      optional bool sync_enabled = 20 [(.google.api.field_behavior) = IMMUTABLE];
      Specified by:
      hasSyncEnabled in interface ExperimentOrBuilder
      Returns:
      Whether the syncEnabled field is set.
    • getSyncEnabled

      public boolean getSyncEnabled()
       Immutable. Set to true if changes to base campaigns should be synced to the
       trial campaigns. Any changes made directly to trial campaigns will be
       preserved. This field can only be set when the experiment is being created.
       
      optional bool sync_enabled = 20 [(.google.api.field_behavior) = IMMUTABLE];
      Specified by:
      getSyncEnabled in interface ExperimentOrBuilder
      Returns:
      The syncEnabled.
    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessageV3
    • writeTo

      public void writeTo(com.google.protobuf.CodedOutputStream output) throws IOException
      Specified by:
      writeTo in interface com.google.protobuf.MessageLite
      Overrides:
      writeTo in class com.google.protobuf.GeneratedMessageV3
      Throws:
      IOException
    • getSerializedSize

      public int getSerializedSize()
      Specified by:
      getSerializedSize in interface com.google.protobuf.MessageLite
      Overrides:
      getSerializedSize in class com.google.protobuf.GeneratedMessageV3
    • equals

      public boolean equals(Object obj)
      Specified by:
      equals in interface com.google.protobuf.Message
      Overrides:
      equals in class com.google.protobuf.AbstractMessage
    • hashCode

      public int hashCode()
      Specified by:
      hashCode in interface com.google.protobuf.Message
      Overrides:
      hashCode in class com.google.protobuf.AbstractMessage
    • parseFrom

      public static Experiment parseFrom(ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Experiment parseFrom(ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Experiment parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Experiment parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Experiment parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Experiment parseFrom(byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException
      Throws:
      com.google.protobuf.InvalidProtocolBufferException
    • parseFrom

      public static Experiment parseFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static Experiment parseFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static Experiment parseDelimitedFrom(InputStream input) throws IOException
      Throws:
      IOException
    • parseDelimitedFrom

      public static Experiment parseDelimitedFrom(InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • parseFrom

      public static Experiment parseFrom(com.google.protobuf.CodedInputStream input) throws IOException
      Throws:
      IOException
    • parseFrom

      public static Experiment parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Throws:
      IOException
    • newBuilderForType

      public Experiment.Builder newBuilderForType()
      Specified by:
      newBuilderForType in interface com.google.protobuf.Message
      Specified by:
      newBuilderForType in interface com.google.protobuf.MessageLite
    • newBuilder

      public static Experiment.Builder newBuilder()
    • newBuilder

      public static Experiment.Builder newBuilder(Experiment prototype)
    • toBuilder

      public Experiment.Builder toBuilder()
      Specified by:
      toBuilder in interface com.google.protobuf.Message
      Specified by:
      toBuilder in interface com.google.protobuf.MessageLite
    • newBuilderForType

      protected Experiment.Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent)
      Specified by:
      newBuilderForType in class com.google.protobuf.GeneratedMessageV3
    • getDefaultInstance

      public static Experiment getDefaultInstance()
    • parser

      public static com.google.protobuf.Parser<Experiment> parser()
    • getParserForType

      public com.google.protobuf.Parser<Experiment> getParserForType()
      Specified by:
      getParserForType in interface com.google.protobuf.Message
      Specified by:
      getParserForType in interface com.google.protobuf.MessageLite
      Overrides:
      getParserForType in class com.google.protobuf.GeneratedMessageV3
    • getDefaultInstanceForType

      public Experiment getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder