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

com.google.protobuf.FieldDescriptorProtoKt.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("-initializefieldDescriptorProto")
public inline fun fieldDescriptorProto(block: com.google.protobuf.FieldDescriptorProtoKt.Dsl.() -> kotlin.Unit): com.google.protobuf.DescriptorProtos.FieldDescriptorProto =
  com.google.protobuf.FieldDescriptorProtoKt.Dsl._create(com.google.protobuf.DescriptorProtos.FieldDescriptorProto.newBuilder()).apply { block() }._build()
/**
 * Protobuf type `google.protobuf.FieldDescriptorProto`
 */
public object FieldDescriptorProtoKt {
  @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.FieldDescriptorProto.Builder
  ) {
    public companion object {
      @kotlin.jvm.JvmSynthetic
      @kotlin.PublishedApi
      internal fun _create(builder: com.google.protobuf.DescriptorProtos.FieldDescriptorProto.Builder): Dsl = Dsl(builder)
    }

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

    /**
     * `optional string name = 1 [json_name = "name"];`
     */
    public var name: kotlin.String
      @JvmName("getName")
      get() = _builder.getName()
      @JvmName("setName")
      set(value) {
        _builder.setName(value)
      }
    /**
     * `optional string name = 1 [json_name = "name"];`
     */
    public fun clearName() {
      _builder.clearName()
    }
    /**
     * `optional string name = 1 [json_name = "name"];`
     * @return Whether the name field is set.
     */
    public fun hasName(): kotlin.Boolean {
      return _builder.hasName()
    }

    /**
     * `optional int32 number = 3 [json_name = "number"];`
     */
    public var number: kotlin.Int
      @JvmName("getNumber")
      get() = _builder.getNumber()
      @JvmName("setNumber")
      set(value) {
        _builder.setNumber(value)
      }
    /**
     * `optional int32 number = 3 [json_name = "number"];`
     */
    public fun clearNumber() {
      _builder.clearNumber()
    }
    /**
     * `optional int32 number = 3 [json_name = "number"];`
     * @return Whether the number field is set.
     */
    public fun hasNumber(): kotlin.Boolean {
      return _builder.hasNumber()
    }

    /**
     * `optional .google.protobuf.FieldDescriptorProto.Label label = 4 [json_name = "label"];`
     */
    public var label: com.google.protobuf.DescriptorProtos.FieldDescriptorProto.Label
      @JvmName("getLabel")
      get() = _builder.getLabel()
      @JvmName("setLabel")
      set(value) {
        _builder.setLabel(value)
      }
    /**
     * `optional .google.protobuf.FieldDescriptorProto.Label label = 4 [json_name = "label"];`
     */
    public fun clearLabel() {
      _builder.clearLabel()
    }
    /**
     * `optional .google.protobuf.FieldDescriptorProto.Label label = 4 [json_name = "label"];`
     * @return Whether the label field is set.
     */
    public fun hasLabel(): kotlin.Boolean {
      return _builder.hasLabel()
    }

    /**
     * `optional .google.protobuf.FieldDescriptorProto.Type type = 5 [json_name = "type"];`
     */
    public var type: com.google.protobuf.DescriptorProtos.FieldDescriptorProto.Type
      @JvmName("getType")
      get() = _builder.getType()
      @JvmName("setType")
      set(value) {
        _builder.setType(value)
      }
    /**
     * `optional .google.protobuf.FieldDescriptorProto.Type type = 5 [json_name = "type"];`
     */
    public fun clearType() {
      _builder.clearType()
    }
    /**
     * `optional .google.protobuf.FieldDescriptorProto.Type type = 5 [json_name = "type"];`
     * @return Whether the type field is set.
     */
    public fun hasType(): kotlin.Boolean {
      return _builder.hasType()
    }

    /**
     * `optional string type_name = 6 [json_name = "typeName"];`
     */
    public var typeName: kotlin.String
      @JvmName("getTypeName")
      get() = _builder.getTypeName()
      @JvmName("setTypeName")
      set(value) {
        _builder.setTypeName(value)
      }
    /**
     * `optional string type_name = 6 [json_name = "typeName"];`
     */
    public fun clearTypeName() {
      _builder.clearTypeName()
    }
    /**
     * `optional string type_name = 6 [json_name = "typeName"];`
     * @return Whether the typeName field is set.
     */
    public fun hasTypeName(): kotlin.Boolean {
      return _builder.hasTypeName()
    }

    /**
     * `optional string extendee = 2 [json_name = "extendee"];`
     */
    public var extendee: kotlin.String
      @JvmName("getExtendee")
      get() = _builder.getExtendee()
      @JvmName("setExtendee")
      set(value) {
        _builder.setExtendee(value)
      }
    /**
     * `optional string extendee = 2 [json_name = "extendee"];`
     */
    public fun clearExtendee() {
      _builder.clearExtendee()
    }
    /**
     * `optional string extendee = 2 [json_name = "extendee"];`
     * @return Whether the extendee field is set.
     */
    public fun hasExtendee(): kotlin.Boolean {
      return _builder.hasExtendee()
    }

    /**
     * `optional string default_value = 7 [json_name = "defaultValue"];`
     */
    public var defaultValue: kotlin.String
      @JvmName("getDefaultValue")
      get() = _builder.getDefaultValue()
      @JvmName("setDefaultValue")
      set(value) {
        _builder.setDefaultValue(value)
      }
    /**
     * `optional string default_value = 7 [json_name = "defaultValue"];`
     */
    public fun clearDefaultValue() {
      _builder.clearDefaultValue()
    }
    /**
     * `optional string default_value = 7 [json_name = "defaultValue"];`
     * @return Whether the defaultValue field is set.
     */
    public fun hasDefaultValue(): kotlin.Boolean {
      return _builder.hasDefaultValue()
    }

    /**
     * `optional int32 oneof_index = 9 [json_name = "oneofIndex"];`
     */
    public var oneofIndex: kotlin.Int
      @JvmName("getOneofIndex")
      get() = _builder.getOneofIndex()
      @JvmName("setOneofIndex")
      set(value) {
        _builder.setOneofIndex(value)
      }
    /**
     * `optional int32 oneof_index = 9 [json_name = "oneofIndex"];`
     */
    public fun clearOneofIndex() {
      _builder.clearOneofIndex()
    }
    /**
     * `optional int32 oneof_index = 9 [json_name = "oneofIndex"];`
     * @return Whether the oneofIndex field is set.
     */
    public fun hasOneofIndex(): kotlin.Boolean {
      return _builder.hasOneofIndex()
    }

    /**
     * `optional string json_name = 10 [json_name = "jsonName"];`
     */
    public var jsonName: kotlin.String
      @JvmName("getJsonName")
      get() = _builder.getJsonName()
      @JvmName("setJsonName")
      set(value) {
        _builder.setJsonName(value)
      }
    /**
     * `optional string json_name = 10 [json_name = "jsonName"];`
     */
    public fun clearJsonName() {
      _builder.clearJsonName()
    }
    /**
     * `optional string json_name = 10 [json_name = "jsonName"];`
     * @return Whether the jsonName field is set.
     */
    public fun hasJsonName(): kotlin.Boolean {
      return _builder.hasJsonName()
    }

    /**
     * `optional .google.protobuf.FieldOptions options = 8 [json_name = "options"];`
     */
    public var options: com.google.protobuf.DescriptorProtos.FieldOptions
      @JvmName("getOptions")
      get() = _builder.getOptions()
      @JvmName("setOptions")
      set(value) {
        _builder.setOptions(value)
      }
    /**
     * `optional .google.protobuf.FieldOptions options = 8 [json_name = "options"];`
     */
    public fun clearOptions() {
      _builder.clearOptions()
    }
    /**
     * `optional .google.protobuf.FieldOptions options = 8 [json_name = "options"];`
     * @return Whether the options field is set.
     */
    public fun hasOptions(): kotlin.Boolean {
      return _builder.hasOptions()
    }
    public val FieldDescriptorProtoKt.Dsl.optionsOrNull: com.google.protobuf.DescriptorProtos.FieldOptions?
      get() = _builder.optionsOrNull

    /**
     * `optional bool proto3_optional = 17 [json_name = "proto3Optional"];`
     */
    public var proto3Optional: kotlin.Boolean
      @JvmName("getProto3Optional")
      get() = _builder.getProto3Optional()
      @JvmName("setProto3Optional")
      set(value) {
        _builder.setProto3Optional(value)
      }
    /**
     * `optional bool proto3_optional = 17 [json_name = "proto3Optional"];`
     */
    public fun clearProto3Optional() {
      _builder.clearProto3Optional()
    }
    /**
     * `optional bool proto3_optional = 17 [json_name = "proto3Optional"];`
     * @return Whether the proto3Optional field is set.
     */
    public fun hasProto3Optional(): kotlin.Boolean {
      return _builder.hasProto3Optional()
    }
  }
}
@kotlin.jvm.JvmSynthetic
public inline fun com.google.protobuf.DescriptorProtos.FieldDescriptorProto.copy(block: com.google.protobuf.FieldDescriptorProtoKt.Dsl.() -> kotlin.Unit): com.google.protobuf.DescriptorProtos.FieldDescriptorProto =
  com.google.protobuf.FieldDescriptorProtoKt.Dsl._create(this.toBuilder()).apply { block() }._build()

public val com.google.protobuf.DescriptorProtos.FieldDescriptorProtoOrBuilder.optionsOrNull: com.google.protobuf.DescriptorProtos.FieldOptions?
  get() = if (hasOptions()) getOptions() else null





© 2015 - 2024 Weber Informatics LLC | Privacy Policy