com.google.protobuf.SourceContextKt.kt Maven / Gradle / Ivy
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: google/protobuf/source_context.proto
// Generated files should ignore deprecation warnings
@file:Suppress("DEPRECATION")
package com.google.protobuf;
@kotlin.jvm.JvmName("-initializesourceContext")
public inline fun sourceContext(block: com.google.protobuf.SourceContextKt.Dsl.() -> kotlin.Unit): com.google.protobuf.SourceContext =
com.google.protobuf.SourceContextKt.Dsl._create(com.google.protobuf.SourceContext.newBuilder()).apply { block() }._build()
/**
* ```
* `SourceContext` represents information about the source of a
* protobuf element, like the file in which it is defined.
* ```
*
* Protobuf type `google.protobuf.SourceContext`
*/
public object SourceContextKt {
@kotlin.OptIn(com.google.protobuf.kotlin.OnlyForUseByGeneratedProtoCode::class)
@com.google.protobuf.kotlin.ProtoDslMarker
public class Dsl private constructor(
private val _builder: com.google.protobuf.SourceContext.Builder
) {
public companion object {
@kotlin.jvm.JvmSynthetic
@kotlin.PublishedApi
internal fun _create(builder: com.google.protobuf.SourceContext.Builder): Dsl = Dsl(builder)
}
@kotlin.jvm.JvmSynthetic
@kotlin.PublishedApi
internal fun _build(): com.google.protobuf.SourceContext = _builder.build()
/**
* ```
* The path-qualified name of the .proto file that contained the associated
* protobuf element. For example: `"google/protobuf/source_context.proto"`.
* ```
*
* `string file_name = 1;`
*/
public var fileName: kotlin.String
@JvmName("getFileName")
get() = _builder.getFileName()
@JvmName("setFileName")
set(value) {
_builder.setFileName(value)
}
/**
* ```
* The path-qualified name of the .proto file that contained the associated
* protobuf element. For example: `"google/protobuf/source_context.proto"`.
* ```
*
* `string file_name = 1;`
*/
public fun clearFileName() {
_builder.clearFileName()
}
}
}
@kotlin.jvm.JvmSynthetic
public inline fun com.google.protobuf.SourceContext.copy(block: `com.google.protobuf`.SourceContextKt.Dsl.() -> kotlin.Unit): com.google.protobuf.SourceContext =
`com.google.protobuf`.SourceContextKt.Dsl._create(this.toBuilder()).apply { block() }._build()