/*
 * Copyright 2020 Google LLC
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     https://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: google/api/servicecontrol/v1/operation.proto

package com.google.api.servicecontrol.v1;

public interface OperationOrBuilder
    extends
    // @@protoc_insertion_point(interface_extends:google.api.servicecontrol.v1.Operation)
    com.google.protobuf.MessageOrBuilder {

  /**
   *
   *
   * <pre>
   * Identity of the operation. This must be unique within the scope of the
   * service that generated the operation. If the service calls
   * Check() and Report() on the same operation, the two calls should carry
   * the same id.
   * UUID version 4 is recommended, though not required.
   * In scenarios where an operation is computed from existing information
   * and an idempotent id is desirable for deduplication purpose, UUID version 5
   * is recommended. See RFC 4122 for details.
   * </pre>
   *
   * <code>string operation_id = 1;</code>
   *
   * @return The operationId.
   */
  java.lang.String getOperationId();
  /**
   *
   *
   * <pre>
   * Identity of the operation. This must be unique within the scope of the
   * service that generated the operation. If the service calls
   * Check() and Report() on the same operation, the two calls should carry
   * the same id.
   * UUID version 4 is recommended, though not required.
   * In scenarios where an operation is computed from existing information
   * and an idempotent id is desirable for deduplication purpose, UUID version 5
   * is recommended. See RFC 4122 for details.
   * </pre>
   *
   * <code>string operation_id = 1;</code>
   *
   * @return The bytes for operationId.
   */
  com.google.protobuf.ByteString getOperationIdBytes();

  /**
   *
   *
   * <pre>
   * Fully qualified name of the operation. Reserved for future use.
   * </pre>
   *
   * <code>string operation_name = 2;</code>
   *
   * @return The operationName.
   */
  java.lang.String getOperationName();
  /**
   *
   *
   * <pre>
   * Fully qualified name of the operation. Reserved for future use.
   * </pre>
   *
   * <code>string operation_name = 2;</code>
   *
   * @return The bytes for operationName.
   */
  com.google.protobuf.ByteString getOperationNameBytes();

  /**
   *
   *
   * <pre>
   * Identity of the consumer who is using the service.
   * This field should be filled in for the operations initiated by a
   * consumer, but not for service-initiated operations that are
   * not related to a specific consumer.
   * - This can be in one of the following formats:
   *     - project:PROJECT_ID,
   *     - project`_`number:PROJECT_NUMBER,
   *     - projects/PROJECT_ID or PROJECT_NUMBER,
   *     - folders/FOLDER_NUMBER,
   *     - organizations/ORGANIZATION_NUMBER,
   *     - api`_`key:API_KEY.
   * </pre>
   *
   * <code>string consumer_id = 3;</code>
   *
   * @return The consumerId.
   */
  java.lang.String getConsumerId();
  /**
   *
   *
   * <pre>
   * Identity of the consumer who is using the service.
   * This field should be filled in for the operations initiated by a
   * consumer, but not for service-initiated operations that are
   * not related to a specific consumer.
   * - This can be in one of the following formats:
   *     - project:PROJECT_ID,
   *     - project`_`number:PROJECT_NUMBER,
   *     - projects/PROJECT_ID or PROJECT_NUMBER,
   *     - folders/FOLDER_NUMBER,
   *     - organizations/ORGANIZATION_NUMBER,
   *     - api`_`key:API_KEY.
   * </pre>
   *
   * <code>string consumer_id = 3;</code>
   *
   * @return The bytes for consumerId.
   */
  com.google.protobuf.ByteString getConsumerIdBytes();

  /**
   *
   *
   * <pre>
   * Required. Start time of the operation.
   * </pre>
   *
   * <code>.google.protobuf.Timestamp start_time = 4;</code>
   *
   * @return Whether the startTime field is set.
   */
  boolean hasStartTime();
  /**
   *
   *
   * <pre>
   * Required. Start time of the operation.
   * </pre>
   *
   * <code>.google.protobuf.Timestamp start_time = 4;</code>
   *
   * @return The startTime.
   */
  com.google.protobuf.Timestamp getStartTime();
  /**
   *
   *
   * <pre>
   * Required. Start time of the operation.
   * </pre>
   *
   * <code>.google.protobuf.Timestamp start_time = 4;</code>
   */
  com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder();

  /**
   *
   *
   * <pre>
   * End time of the operation.
   * Required when the operation is used in
   * [ServiceController.Report][google.api.servicecontrol.v1.ServiceController.Report],
   * but optional when the operation is used in
   * [ServiceController.Check][google.api.servicecontrol.v1.ServiceController.Check].
   * </pre>
   *
   * <code>.google.protobuf.Timestamp end_time = 5;</code>
   *
   * @return Whether the endTime field is set.
   */
  boolean hasEndTime();
  /**
   *
   *
   * <pre>
   * End time of the operation.
   * Required when the operation is used in
   * [ServiceController.Report][google.api.servicecontrol.v1.ServiceController.Report],
   * but optional when the operation is used in
   * [ServiceController.Check][google.api.servicecontrol.v1.ServiceController.Check].
   * </pre>
   *
   * <code>.google.protobuf.Timestamp end_time = 5;</code>
   *
   * @return The endTime.
   */
  com.google.protobuf.Timestamp getEndTime();
  /**
   *
   *
   * <pre>
   * End time of the operation.
   * Required when the operation is used in
   * [ServiceController.Report][google.api.servicecontrol.v1.ServiceController.Report],
   * but optional when the operation is used in
   * [ServiceController.Check][google.api.servicecontrol.v1.ServiceController.Check].
   * </pre>
   *
   * <code>.google.protobuf.Timestamp end_time = 5;</code>
   */
  com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder();

  /**
   *
   *
   * <pre>
   * Labels describing the operation. Only the following labels are allowed:
   * - Labels describing monitored resources as defined in
   *   the service configuration.
   * - Default labels of metric values. When specified, labels defined in the
   *   metric value override these default.
   * - The following labels defined by Google Cloud Platform:
   *     - `cloud.googleapis.com/location` describing the location where the
   *        operation happened,
   *     - `servicecontrol.googleapis.com/user_agent` describing the user agent
   *        of the API request,
   *     - `servicecontrol.googleapis.com/service_agent` describing the service
   *        used to handle the API request (e.g. ESP),
   *     - `servicecontrol.googleapis.com/platform` describing the platform
   *        where the API is served, such as App Engine, Compute Engine, or
   *        Kubernetes Engine.
   * </pre>
   *
   * <code>map&lt;string, string&gt; labels = 6;</code>
   */
  int getLabelsCount();
  /**
   *
   *
   * <pre>
   * Labels describing the operation. Only the following labels are allowed:
   * - Labels describing monitored resources as defined in
   *   the service configuration.
   * - Default labels of metric values. When specified, labels defined in the
   *   metric value override these default.
   * - The following labels defined by Google Cloud Platform:
   *     - `cloud.googleapis.com/location` describing the location where the
   *        operation happened,
   *     - `servicecontrol.googleapis.com/user_agent` describing the user agent
   *        of the API request,
   *     - `servicecontrol.googleapis.com/service_agent` describing the service
   *        used to handle the API request (e.g. ESP),
   *     - `servicecontrol.googleapis.com/platform` describing the platform
   *        where the API is served, such as App Engine, Compute Engine, or
   *        Kubernetes Engine.
   * </pre>
   *
   * <code>map&lt;string, string&gt; labels = 6;</code>
   */
  boolean containsLabels(java.lang.String key);
  /** Use {@link #getLabelsMap()} instead. */
  @java.lang.Deprecated
  java.util.Map<java.lang.String, java.lang.String> getLabels();
  /**
   *
   *
   * <pre>
   * Labels describing the operation. Only the following labels are allowed:
   * - Labels describing monitored resources as defined in
   *   the service configuration.
   * - Default labels of metric values. When specified, labels defined in the
   *   metric value override these default.
   * - The following labels defined by Google Cloud Platform:
   *     - `cloud.googleapis.com/location` describing the location where the
   *        operation happened,
   *     - `servicecontrol.googleapis.com/user_agent` describing the user agent
   *        of the API request,
   *     - `servicecontrol.googleapis.com/service_agent` describing the service
   *        used to handle the API request (e.g. ESP),
   *     - `servicecontrol.googleapis.com/platform` describing the platform
   *        where the API is served, such as App Engine, Compute Engine, or
   *        Kubernetes Engine.
   * </pre>
   *
   * <code>map&lt;string, string&gt; labels = 6;</code>
   */
  java.util.Map<java.lang.String, java.lang.String> getLabelsMap();
  /**
   *
   *
   * <pre>
   * Labels describing the operation. Only the following labels are allowed:
   * - Labels describing monitored resources as defined in
   *   the service configuration.
   * - Default labels of metric values. When specified, labels defined in the
   *   metric value override these default.
   * - The following labels defined by Google Cloud Platform:
   *     - `cloud.googleapis.com/location` describing the location where the
   *        operation happened,
   *     - `servicecontrol.googleapis.com/user_agent` describing the user agent
   *        of the API request,
   *     - `servicecontrol.googleapis.com/service_agent` describing the service
   *        used to handle the API request (e.g. ESP),
   *     - `servicecontrol.googleapis.com/platform` describing the platform
   *        where the API is served, such as App Engine, Compute Engine, or
   *        Kubernetes Engine.
   * </pre>
   *
   * <code>map&lt;string, string&gt; labels = 6;</code>
   */
  /* nullable */
  java.lang.String getLabelsOrDefault(
      java.lang.String key,
      /* nullable */
      java.lang.String defaultValue);
  /**
   *
   *
   * <pre>
   * Labels describing the operation. Only the following labels are allowed:
   * - Labels describing monitored resources as defined in
   *   the service configuration.
   * - Default labels of metric values. When specified, labels defined in the
   *   metric value override these default.
   * - The following labels defined by Google Cloud Platform:
   *     - `cloud.googleapis.com/location` describing the location where the
   *        operation happened,
   *     - `servicecontrol.googleapis.com/user_agent` describing the user agent
   *        of the API request,
   *     - `servicecontrol.googleapis.com/service_agent` describing the service
   *        used to handle the API request (e.g. ESP),
   *     - `servicecontrol.googleapis.com/platform` describing the platform
   *        where the API is served, such as App Engine, Compute Engine, or
   *        Kubernetes Engine.
   * </pre>
   *
   * <code>map&lt;string, string&gt; labels = 6;</code>
   */
  java.lang.String getLabelsOrThrow(java.lang.String key);

  /**
   *
   *
   * <pre>
   * Represents information about this operation. Each MetricValueSet
   * corresponds to a metric defined in the service configuration.
   * The data type used in the MetricValueSet must agree with
   * the data type specified in the metric definition.
   * Within a single operation, it is not allowed to have more than one
   * MetricValue instances that have the same metric names and identical
   * label value combinations. If a request has such duplicated MetricValue
   * instances, the entire request is rejected with
   * an invalid argument error.
   * </pre>
   *
   * <code>repeated .google.api.servicecontrol.v1.MetricValueSet metric_value_sets = 7;</code>
   */
  java.util.List<com.google.api.servicecontrol.v1.MetricValueSet> getMetricValueSetsList();
  /**
   *
   *
   * <pre>
   * Represents information about this operation. Each MetricValueSet
   * corresponds to a metric defined in the service configuration.
   * The data type used in the MetricValueSet must agree with
   * the data type specified in the metric definition.
   * Within a single operation, it is not allowed to have more than one
   * MetricValue instances that have the same metric names and identical
   * label value combinations. If a request has such duplicated MetricValue
   * instances, the entire request is rejected with
   * an invalid argument error.
   * </pre>
   *
   * <code>repeated .google.api.servicecontrol.v1.MetricValueSet metric_value_sets = 7;</code>
   */
  com.google.api.servicecontrol.v1.MetricValueSet getMetricValueSets(int index);
  /**
   *
   *
   * <pre>
   * Represents information about this operation. Each MetricValueSet
   * corresponds to a metric defined in the service configuration.
   * The data type used in the MetricValueSet must agree with
   * the data type specified in the metric definition.
   * Within a single operation, it is not allowed to have more than one
   * MetricValue instances that have the same metric names and identical
   * label value combinations. If a request has such duplicated MetricValue
   * instances, the entire request is rejected with
   * an invalid argument error.
   * </pre>
   *
   * <code>repeated .google.api.servicecontrol.v1.MetricValueSet metric_value_sets = 7;</code>
   */
  int getMetricValueSetsCount();
  /**
   *
   *
   * <pre>
   * Represents information about this operation. Each MetricValueSet
   * corresponds to a metric defined in the service configuration.
   * The data type used in the MetricValueSet must agree with
   * the data type specified in the metric definition.
   * Within a single operation, it is not allowed to have more than one
   * MetricValue instances that have the same metric names and identical
   * label value combinations. If a request has such duplicated MetricValue
   * instances, the entire request is rejected with
   * an invalid argument error.
   * </pre>
   *
   * <code>repeated .google.api.servicecontrol.v1.MetricValueSet metric_value_sets = 7;</code>
   */
  java.util.List<? extends com.google.api.servicecontrol.v1.MetricValueSetOrBuilder>
      getMetricValueSetsOrBuilderList();
  /**
   *
   *
   * <pre>
   * Represents information about this operation. Each MetricValueSet
   * corresponds to a metric defined in the service configuration.
   * The data type used in the MetricValueSet must agree with
   * the data type specified in the metric definition.
   * Within a single operation, it is not allowed to have more than one
   * MetricValue instances that have the same metric names and identical
   * label value combinations. If a request has such duplicated MetricValue
   * instances, the entire request is rejected with
   * an invalid argument error.
   * </pre>
   *
   * <code>repeated .google.api.servicecontrol.v1.MetricValueSet metric_value_sets = 7;</code>
   */
  com.google.api.servicecontrol.v1.MetricValueSetOrBuilder getMetricValueSetsOrBuilder(int index);

  /**
   *
   *
   * <pre>
   * Represents information to be logged.
   * </pre>
   *
   * <code>repeated .google.api.servicecontrol.v1.LogEntry log_entries = 8;</code>
   */
  java.util.List<com.google.api.servicecontrol.v1.LogEntry> getLogEntriesList();
  /**
   *
   *
   * <pre>
   * Represents information to be logged.
   * </pre>
   *
   * <code>repeated .google.api.servicecontrol.v1.LogEntry log_entries = 8;</code>
   */
  com.google.api.servicecontrol.v1.LogEntry getLogEntries(int index);
  /**
   *
   *
   * <pre>
   * Represents information to be logged.
   * </pre>
   *
   * <code>repeated .google.api.servicecontrol.v1.LogEntry log_entries = 8;</code>
   */
  int getLogEntriesCount();
  /**
   *
   *
   * <pre>
   * Represents information to be logged.
   * </pre>
   *
   * <code>repeated .google.api.servicecontrol.v1.LogEntry log_entries = 8;</code>
   */
  java.util.List<? extends com.google.api.servicecontrol.v1.LogEntryOrBuilder>
      getLogEntriesOrBuilderList();
  /**
   *
   *
   * <pre>
   * Represents information to be logged.
   * </pre>
   *
   * <code>repeated .google.api.servicecontrol.v1.LogEntry log_entries = 8;</code>
   */
  com.google.api.servicecontrol.v1.LogEntryOrBuilder getLogEntriesOrBuilder(int index);

  /**
   *
   *
   * <pre>
   * DO NOT USE. This is an experimental field.
   * </pre>
   *
   * <code>.google.api.servicecontrol.v1.Operation.Importance importance = 11;</code>
   *
   * @return The enum numeric value on the wire for importance.
   */
  int getImportanceValue();
  /**
   *
   *
   * <pre>
   * DO NOT USE. This is an experimental field.
   * </pre>
   *
   * <code>.google.api.servicecontrol.v1.Operation.Importance importance = 11;</code>
   *
   * @return The importance.
   */
  com.google.api.servicecontrol.v1.Operation.Importance getImportance();

  /**
   *
   *
   * <pre>
   * Unimplemented.
   * </pre>
   *
   * <code>repeated .google.protobuf.Any extensions = 16;</code>
   */
  java.util.List<com.google.protobuf.Any> getExtensionsList();
  /**
   *
   *
   * <pre>
   * Unimplemented.
   * </pre>
   *
   * <code>repeated .google.protobuf.Any extensions = 16;</code>
   */
  com.google.protobuf.Any getExtensions(int index);
  /**
   *
   *
   * <pre>
   * Unimplemented.
   * </pre>
   *
   * <code>repeated .google.protobuf.Any extensions = 16;</code>
   */
  int getExtensionsCount();
  /**
   *
   *
   * <pre>
   * Unimplemented.
   * </pre>
   *
   * <code>repeated .google.protobuf.Any extensions = 16;</code>
   */
  java.util.List<? extends com.google.protobuf.AnyOrBuilder> getExtensionsOrBuilderList();
  /**
   *
   *
   * <pre>
   * Unimplemented.
   * </pre>
   *
   * <code>repeated .google.protobuf.Any extensions = 16;</code>
   */
  com.google.protobuf.AnyOrBuilder getExtensionsOrBuilder(int index);
}
