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

com.google.protobuf.FeatureSetKt.kt Maven / Gradle / Ivy

Go to download

Kotlin core Protocol Buffers library. Protocol Buffers are a way of encoding structured data in an efficient yet extensible format.

There is a newer version: 4.29.0-RC2
Show newest version
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/protobuf/descriptor.proto

// Generated files should ignore deprecation warnings
@file:Suppress("DEPRECATION")
package com.google.protobuf;

@kotlin.jvm.JvmName("-initializefeatureSet")
public inline fun featureSet(block: com.google.protobuf.FeatureSetKt.Dsl.() -> kotlin.Unit): com.google.protobuf.DescriptorProtos.FeatureSet =
  com.google.protobuf.FeatureSetKt.Dsl._create(com.google.protobuf.DescriptorProtos.FeatureSet.newBuilder()).apply { block() }._build()
/**
 * Protobuf type `google.protobuf.FeatureSet`
 */
public object FeatureSetKt {
  @kotlin.OptIn(com.google.protobuf.kotlin.OnlyForUseByGeneratedProtoCode::class)
  @com.google.protobuf.kotlin.ProtoDslMarker
  public class Dsl private constructor(
    private val _builder: com.google.protobuf.DescriptorProtos.FeatureSet.Builder
  ) {
    public companion object {
      @kotlin.jvm.JvmSynthetic
      @kotlin.PublishedApi
      internal fun _create(builder: com.google.protobuf.DescriptorProtos.FeatureSet.Builder): Dsl = Dsl(builder)
    }

    @kotlin.jvm.JvmSynthetic
    @kotlin.PublishedApi
    internal fun _build(): com.google.protobuf.DescriptorProtos.FeatureSet = _builder.build()

    /**
     * `optional .google.protobuf.FeatureSet.FieldPresence field_presence = 1 [json_name = "fieldPresence", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public var fieldPresence: com.google.protobuf.DescriptorProtos.FeatureSet.FieldPresence
      @JvmName("getFieldPresence")
      get() = _builder.getFieldPresence()
      @JvmName("setFieldPresence")
      set(value) {
        _builder.setFieldPresence(value)
      }
    /**
     * `optional .google.protobuf.FeatureSet.FieldPresence field_presence = 1 [json_name = "fieldPresence", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public fun clearFieldPresence() {
      _builder.clearFieldPresence()
    }
    /**
     * `optional .google.protobuf.FeatureSet.FieldPresence field_presence = 1 [json_name = "fieldPresence", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     * @return Whether the fieldPresence field is set.
     */
    public fun hasFieldPresence(): kotlin.Boolean {
      return _builder.hasFieldPresence()
    }

    /**
     * `optional .google.protobuf.FeatureSet.EnumType enum_type = 2 [json_name = "enumType", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_ENUM, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public var enumType: com.google.protobuf.DescriptorProtos.FeatureSet.EnumType
      @JvmName("getEnumType")
      get() = _builder.getEnumType()
      @JvmName("setEnumType")
      set(value) {
        _builder.setEnumType(value)
      }
    /**
     * `optional .google.protobuf.FeatureSet.EnumType enum_type = 2 [json_name = "enumType", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_ENUM, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public fun clearEnumType() {
      _builder.clearEnumType()
    }
    /**
     * `optional .google.protobuf.FeatureSet.EnumType enum_type = 2 [json_name = "enumType", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_ENUM, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     * @return Whether the enumType field is set.
     */
    public fun hasEnumType(): kotlin.Boolean {
      return _builder.hasEnumType()
    }

    /**
     * `optional .google.protobuf.FeatureSet.RepeatedFieldEncoding repeated_field_encoding = 3 [json_name = "repeatedFieldEncoding", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public var repeatedFieldEncoding: com.google.protobuf.DescriptorProtos.FeatureSet.RepeatedFieldEncoding
      @JvmName("getRepeatedFieldEncoding")
      get() = _builder.getRepeatedFieldEncoding()
      @JvmName("setRepeatedFieldEncoding")
      set(value) {
        _builder.setRepeatedFieldEncoding(value)
      }
    /**
     * `optional .google.protobuf.FeatureSet.RepeatedFieldEncoding repeated_field_encoding = 3 [json_name = "repeatedFieldEncoding", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public fun clearRepeatedFieldEncoding() {
      _builder.clearRepeatedFieldEncoding()
    }
    /**
     * `optional .google.protobuf.FeatureSet.RepeatedFieldEncoding repeated_field_encoding = 3 [json_name = "repeatedFieldEncoding", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     * @return Whether the repeatedFieldEncoding field is set.
     */
    public fun hasRepeatedFieldEncoding(): kotlin.Boolean {
      return _builder.hasRepeatedFieldEncoding()
    }

    /**
     * `optional .google.protobuf.FeatureSet.StringFieldValidation string_field_validation = 4 [json_name = "stringFieldValidation", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public var stringFieldValidation: com.google.protobuf.DescriptorProtos.FeatureSet.StringFieldValidation
      @JvmName("getStringFieldValidation")
      get() = _builder.getStringFieldValidation()
      @JvmName("setStringFieldValidation")
      set(value) {
        _builder.setStringFieldValidation(value)
      }
    /**
     * `optional .google.protobuf.FeatureSet.StringFieldValidation string_field_validation = 4 [json_name = "stringFieldValidation", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public fun clearStringFieldValidation() {
      _builder.clearStringFieldValidation()
    }
    /**
     * `optional .google.protobuf.FeatureSet.StringFieldValidation string_field_validation = 4 [json_name = "stringFieldValidation", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     * @return Whether the stringFieldValidation field is set.
     */
    public fun hasStringFieldValidation(): kotlin.Boolean {
      return _builder.hasStringFieldValidation()
    }

    /**
     * `optional .google.protobuf.FeatureSet.MessageEncoding message_encoding = 5 [json_name = "messageEncoding", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public var messageEncoding: com.google.protobuf.DescriptorProtos.FeatureSet.MessageEncoding
      @JvmName("getMessageEncoding")
      get() = _builder.getMessageEncoding()
      @JvmName("setMessageEncoding")
      set(value) {
        _builder.setMessageEncoding(value)
      }
    /**
     * `optional .google.protobuf.FeatureSet.MessageEncoding message_encoding = 5 [json_name = "messageEncoding", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public fun clearMessageEncoding() {
      _builder.clearMessageEncoding()
    }
    /**
     * `optional .google.protobuf.FeatureSet.MessageEncoding message_encoding = 5 [json_name = "messageEncoding", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_FIELD, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     * @return Whether the messageEncoding field is set.
     */
    public fun hasMessageEncoding(): kotlin.Boolean {
      return _builder.hasMessageEncoding()
    }

    /**
     * `optional .google.protobuf.FeatureSet.JsonFormat json_format = 6 [json_name = "jsonFormat", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_MESSAGE, targets = TARGET_TYPE_ENUM, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public var jsonFormat: com.google.protobuf.DescriptorProtos.FeatureSet.JsonFormat
      @JvmName("getJsonFormat")
      get() = _builder.getJsonFormat()
      @JvmName("setJsonFormat")
      set(value) {
        _builder.setJsonFormat(value)
      }
    /**
     * `optional .google.protobuf.FeatureSet.JsonFormat json_format = 6 [json_name = "jsonFormat", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_MESSAGE, targets = TARGET_TYPE_ENUM, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     */
    public fun clearJsonFormat() {
      _builder.clearJsonFormat()
    }
    /**
     * `optional .google.protobuf.FeatureSet.JsonFormat json_format = 6 [json_name = "jsonFormat", retention = RETENTION_RUNTIME, targets = TARGET_TYPE_MESSAGE, targets = TARGET_TYPE_ENUM, targets = TARGET_TYPE_FILE, edition_defaults = { ... }`
     * @return Whether the jsonFormat field is set.
     */
    public fun hasJsonFormat(): kotlin.Boolean {
      return _builder.hasJsonFormat()
    }

    /**
     * `optional .google.protobuf.FeatureSet raw_features = 999 [json_name = "rawFeatures", targets = TARGET_TYPE_UNKNOWN];`
     */
    public var rawFeatures: com.google.protobuf.DescriptorProtos.FeatureSet
      @JvmName("getRawFeatures")
      get() = _builder.getRawFeatures()
      @JvmName("setRawFeatures")
      set(value) {
        _builder.setRawFeatures(value)
      }
    /**
     * `optional .google.protobuf.FeatureSet raw_features = 999 [json_name = "rawFeatures", targets = TARGET_TYPE_UNKNOWN];`
     */
    public fun clearRawFeatures() {
      _builder.clearRawFeatures()
    }
    /**
     * `optional .google.protobuf.FeatureSet raw_features = 999 [json_name = "rawFeatures", targets = TARGET_TYPE_UNKNOWN];`
     * @return Whether the rawFeatures field is set.
     */
    public fun hasRawFeatures(): kotlin.Boolean {
      return _builder.hasRawFeatures()
    }
    public val FeatureSetKt.Dsl.rawFeaturesOrNull: com.google.protobuf.DescriptorProtos.FeatureSet?
      get() = _builder.rawFeaturesOrNull
    @Suppress("UNCHECKED_CAST")
    @kotlin.jvm.JvmSynthetic
    public operator fun  get(extension: com.google.protobuf.ExtensionLite): T {
      return if (extension.isRepeated) {
        get(extension as com.google.protobuf.ExtensionLite>) as T
      } else {
        _builder.getExtension(extension)
      }
    }

    @kotlin.jvm.JvmSynthetic
    @kotlin.OptIn(com.google.protobuf.kotlin.OnlyForUseByGeneratedProtoCode::class)
    @kotlin.jvm.JvmName("-getRepeatedExtension")
    public operator fun  get(
      extension: com.google.protobuf.ExtensionLite>
    ): com.google.protobuf.kotlin.ExtensionList {
      return com.google.protobuf.kotlin.ExtensionList(extension, _builder.getExtension(extension))
    }

    @kotlin.jvm.JvmSynthetic
    public operator fun contains(extension: com.google.protobuf.ExtensionLite): Boolean {
      return _builder.hasExtension(extension)
    }

    @kotlin.jvm.JvmSynthetic
    public fun clear(extension: com.google.protobuf.ExtensionLite) {
      _builder.clearExtension(extension)
    }

    @kotlin.jvm.JvmSynthetic
    public fun  setExtension(extension: com.google.protobuf.ExtensionLite, value: T) {
      _builder.setExtension(extension, value)
    }

    @kotlin.jvm.JvmSynthetic
    @Suppress("NOTHING_TO_INLINE")
    public inline operator fun > set(
      extension: com.google.protobuf.ExtensionLite,
      value: T
    ) {
      setExtension(extension, value)
    }

    @kotlin.jvm.JvmSynthetic
    @Suppress("NOTHING_TO_INLINE")
    public inline operator fun set(
      extension: com.google.protobuf.ExtensionLite,
      value: com.google.protobuf.ByteString
    ) {
      setExtension(extension, value)
    }

    @kotlin.jvm.JvmSynthetic
    @Suppress("NOTHING_TO_INLINE")
    public inline operator fun  set(
      extension: com.google.protobuf.ExtensionLite,
      value: T
    ) {
      setExtension(extension, value)
    }

    @kotlin.jvm.JvmSynthetic
    public fun  com.google.protobuf.kotlin.ExtensionList.add(value: E) {
      _builder.addExtension(this.extension, value)
    }

    @kotlin.jvm.JvmSynthetic
    @Suppress("NOTHING_TO_INLINE")
    public inline operator fun  com.google.protobuf.kotlin.ExtensionList.plusAssign(value: E) {
      add(value)
    }

    @kotlin.jvm.JvmSynthetic
    public fun  com.google.protobuf.kotlin.ExtensionList.addAll(values: Iterable) {
      for (value in values) {
        add(value)
      }
    }

    @kotlin.jvm.JvmSynthetic
    @Suppress("NOTHING_TO_INLINE")
    public inline operator fun  com.google.protobuf.kotlin.ExtensionList.plusAssign(values: Iterable) {
      addAll(values)
    }

    @kotlin.jvm.JvmSynthetic
    public operator fun  com.google.protobuf.kotlin.ExtensionList.set(index: Int, value: E) {
      _builder.setExtension(this.extension, index, value)
    }

    @kotlin.jvm.JvmSynthetic
    @Suppress("NOTHING_TO_INLINE")
    public inline fun com.google.protobuf.kotlin.ExtensionList<*, com.google.protobuf.DescriptorProtos.FeatureSet>.clear() {
      clear(extension)
    }

  }
}
@kotlin.jvm.JvmSynthetic
public inline fun com.google.protobuf.DescriptorProtos.FeatureSet.copy(block: com.google.protobuf.FeatureSetKt.Dsl.() -> kotlin.Unit): com.google.protobuf.DescriptorProtos.FeatureSet =
  com.google.protobuf.FeatureSetKt.Dsl._create(this.toBuilder()).apply { block() }._build()

public val com.google.protobuf.DescriptorProtos.FeatureSetOrBuilder.rawFeaturesOrNull: com.google.protobuf.DescriptorProtos.FeatureSet?
  get() = if (hasRawFeatures()) getRawFeatures() else null





© 2015 - 2024 Weber Informatics LLC | Privacy Policy