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

build.bazel.remote.execution.v2.ExecuteRequestKt.kt Maven / Gradle / Ivy

// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: build/bazel/remote/execution/v2/remote_execution.proto

// Generated files should ignore deprecation warnings
@file:Suppress("DEPRECATION")
package build.bazel.remote.execution.v2;

@kotlin.jvm.JvmName("-initializeexecuteRequest")
public inline fun executeRequest(block: build.bazel.remote.execution.v2.ExecuteRequestKt.Dsl.() -> kotlin.Unit): build.bazel.remote.execution.v2.ExecuteRequest =
  build.bazel.remote.execution.v2.ExecuteRequestKt.Dsl._create(build.bazel.remote.execution.v2.ExecuteRequest.newBuilder()).apply { block() }._build()
/**
 * ```
 * A request message for
 * [Execution.Execute][build.bazel.remote.execution.v2.Execution.Execute].
 * ```
 *
 * Protobuf type `build.bazel.remote.execution.v2.ExecuteRequest`
 */
public object ExecuteRequestKt {
  @kotlin.OptIn(com.google.protobuf.kotlin.OnlyForUseByGeneratedProtoCode::class)
  @com.google.protobuf.kotlin.ProtoDslMarker
  public class Dsl private constructor(
    private val _builder: build.bazel.remote.execution.v2.ExecuteRequest.Builder
  ) {
    public companion object {
      @kotlin.jvm.JvmSynthetic
      @kotlin.PublishedApi
      internal fun _create(builder: build.bazel.remote.execution.v2.ExecuteRequest.Builder): Dsl = Dsl(builder)
    }

    @kotlin.jvm.JvmSynthetic
    @kotlin.PublishedApi
    internal fun _build(): build.bazel.remote.execution.v2.ExecuteRequest = _builder.build()

    /**
     * ```
     * The instance of the execution system to operate against. A server may
     * support multiple instances of the execution system (with their own workers,
     * storage, caches, etc.). The server MAY require use of this field to select
     * between them in an implementation-defined fashion, otherwise it can be
     * omitted.
     * ```
     *
     * `string instance_name = 1;`
     */
    public var instanceName: kotlin.String
      @JvmName("getInstanceName")
      get() = _builder.getInstanceName()
      @JvmName("setInstanceName")
      set(value) {
        _builder.setInstanceName(value)
      }
    /**
     * ```
     * The instance of the execution system to operate against. A server may
     * support multiple instances of the execution system (with their own workers,
     * storage, caches, etc.). The server MAY require use of this field to select
     * between them in an implementation-defined fashion, otherwise it can be
     * omitted.
     * ```
     *
     * `string instance_name = 1;`
     */
    public fun clearInstanceName() {
      _builder.clearInstanceName()
    }

    /**
     * ```
     * If true, the action will be executed even if its result is already
     * present in the [ActionCache][build.bazel.remote.execution.v2.ActionCache].
     * The execution is still allowed to be merged with other in-flight executions
     * of the same action, however - semantically, the service MUST only guarantee
     * that the results of an execution with this field set were not visible
     * before the corresponding execution request was sent.
     * Note that actions from execution requests setting this field set are still
     * eligible to be entered into the action cache upon completion, and services
     * SHOULD overwrite any existing entries that may exist. This allows
     * skip_cache_lookup requests to be used as a mechanism for replacing action
     * cache entries that reference outputs no longer available or that are
     * poisoned in any way.
     * If false, the result may be served from the action cache.
     * ```
     *
     * `bool skip_cache_lookup = 3;`
     */
    public var skipCacheLookup: kotlin.Boolean
      @JvmName("getSkipCacheLookup")
      get() = _builder.getSkipCacheLookup()
      @JvmName("setSkipCacheLookup")
      set(value) {
        _builder.setSkipCacheLookup(value)
      }
    /**
     * ```
     * If true, the action will be executed even if its result is already
     * present in the [ActionCache][build.bazel.remote.execution.v2.ActionCache].
     * The execution is still allowed to be merged with other in-flight executions
     * of the same action, however - semantically, the service MUST only guarantee
     * that the results of an execution with this field set were not visible
     * before the corresponding execution request was sent.
     * Note that actions from execution requests setting this field set are still
     * eligible to be entered into the action cache upon completion, and services
     * SHOULD overwrite any existing entries that may exist. This allows
     * skip_cache_lookup requests to be used as a mechanism for replacing action
     * cache entries that reference outputs no longer available or that are
     * poisoned in any way.
     * If false, the result may be served from the action cache.
     * ```
     *
     * `bool skip_cache_lookup = 3;`
     */
    public fun clearSkipCacheLookup() {
      _builder.clearSkipCacheLookup()
    }

    /**
     * ```
     * The digest of the [Action][build.bazel.remote.execution.v2.Action] to
     * execute.
     * ```
     *
     * `.build.bazel.remote.execution.v2.Digest action_digest = 6;`
     */
    public var actionDigest: build.bazel.remote.execution.v2.Digest
      @JvmName("getActionDigest")
      get() = _builder.getActionDigest()
      @JvmName("setActionDigest")
      set(value) {
        _builder.setActionDigest(value)
      }
    /**
     * ```
     * The digest of the [Action][build.bazel.remote.execution.v2.Action] to
     * execute.
     * ```
     *
     * `.build.bazel.remote.execution.v2.Digest action_digest = 6;`
     */
    public fun clearActionDigest() {
      _builder.clearActionDigest()
    }
    /**
     * ```
     * The digest of the [Action][build.bazel.remote.execution.v2.Action] to
     * execute.
     * ```
     *
     * `.build.bazel.remote.execution.v2.Digest action_digest = 6;`
     * @return Whether the actionDigest field is set.
     */
    public fun hasActionDigest(): kotlin.Boolean {
      return _builder.hasActionDigest()
    }

    /**
     * ```
     * An optional policy for execution of the action.
     * The server will have a default policy if this is not provided.
     * ```
     *
     * `.build.bazel.remote.execution.v2.ExecutionPolicy execution_policy = 7;`
     */
    public var executionPolicy: build.bazel.remote.execution.v2.ExecutionPolicy
      @JvmName("getExecutionPolicy")
      get() = _builder.getExecutionPolicy()
      @JvmName("setExecutionPolicy")
      set(value) {
        _builder.setExecutionPolicy(value)
      }
    /**
     * ```
     * An optional policy for execution of the action.
     * The server will have a default policy if this is not provided.
     * ```
     *
     * `.build.bazel.remote.execution.v2.ExecutionPolicy execution_policy = 7;`
     */
    public fun clearExecutionPolicy() {
      _builder.clearExecutionPolicy()
    }
    /**
     * ```
     * An optional policy for execution of the action.
     * The server will have a default policy if this is not provided.
     * ```
     *
     * `.build.bazel.remote.execution.v2.ExecutionPolicy execution_policy = 7;`
     * @return Whether the executionPolicy field is set.
     */
    public fun hasExecutionPolicy(): kotlin.Boolean {
      return _builder.hasExecutionPolicy()
    }

    /**
     * ```
     * An optional policy for the results of this execution in the remote cache.
     * The server will have a default policy if this is not provided.
     * This may be applied to both the ActionResult and the associated blobs.
     * ```
     *
     * `.build.bazel.remote.execution.v2.ResultsCachePolicy results_cache_policy = 8;`
     */
    public var resultsCachePolicy: build.bazel.remote.execution.v2.ResultsCachePolicy
      @JvmName("getResultsCachePolicy")
      get() = _builder.getResultsCachePolicy()
      @JvmName("setResultsCachePolicy")
      set(value) {
        _builder.setResultsCachePolicy(value)
      }
    /**
     * ```
     * An optional policy for the results of this execution in the remote cache.
     * The server will have a default policy if this is not provided.
     * This may be applied to both the ActionResult and the associated blobs.
     * ```
     *
     * `.build.bazel.remote.execution.v2.ResultsCachePolicy results_cache_policy = 8;`
     */
    public fun clearResultsCachePolicy() {
      _builder.clearResultsCachePolicy()
    }
    /**
     * ```
     * An optional policy for the results of this execution in the remote cache.
     * The server will have a default policy if this is not provided.
     * This may be applied to both the ActionResult and the associated blobs.
     * ```
     *
     * `.build.bazel.remote.execution.v2.ResultsCachePolicy results_cache_policy = 8;`
     * @return Whether the resultsCachePolicy field is set.
     */
    public fun hasResultsCachePolicy(): kotlin.Boolean {
      return _builder.hasResultsCachePolicy()
    }
  }
}
@kotlin.jvm.JvmSynthetic
public inline fun build.bazel.remote.execution.v2.ExecuteRequest.copy(block: `build.bazel.remote.execution.v2`.ExecuteRequestKt.Dsl.() -> kotlin.Unit): build.bazel.remote.execution.v2.ExecuteRequest =
  `build.bazel.remote.execution.v2`.ExecuteRequestKt.Dsl._create(this.toBuilder()).apply { block() }._build()

public val build.bazel.remote.execution.v2.ExecuteRequestOrBuilder.actionDigestOrNull: build.bazel.remote.execution.v2.Digest?
  get() = if (hasActionDigest()) getActionDigest() else null

public val build.bazel.remote.execution.v2.ExecuteRequestOrBuilder.executionPolicyOrNull: build.bazel.remote.execution.v2.ExecutionPolicy?
  get() = if (hasExecutionPolicy()) getExecutionPolicy() else null

public val build.bazel.remote.execution.v2.ExecuteRequestOrBuilder.resultsCachePolicyOrNull: build.bazel.remote.execution.v2.ResultsCachePolicy?
  get() = if (hasResultsCachePolicy()) getResultsCachePolicy() else null





© 2015 - 2024 Weber Informatics LLC | Privacy Policy