com.google.protobuf.MethodKt.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of protobuf-kotlin Show documentation
Show all versions of protobuf-kotlin Show documentation
Kotlin core Protocol Buffers library. Protocol Buffers are a way of encoding structured data in an
efficient yet extensible format.
// Generated by the protocol buffer compiler. DO NOT EDIT!
// NO CHECKED-IN PROTOBUF GENCODE
// source: google/protobuf/api.proto
// Generated files should ignore deprecation warnings
@file:Suppress("DEPRECATION")
package com.google.protobuf;
@kotlin.jvm.JvmName("-initializemethod")
public inline fun method(block: com.google.protobuf.MethodKt.Dsl.() -> kotlin.Unit): com.google.protobuf.Method =
com.google.protobuf.MethodKt.Dsl._create(com.google.protobuf.Method.newBuilder()).apply { block() }._build()
/**
* Protobuf type `google.protobuf.Method`
*/
public object MethodKt {
@kotlin.OptIn(com.google.protobuf.kotlin.OnlyForUseByGeneratedProtoCode::class)
@com.google.protobuf.kotlin.ProtoDslMarker
public class Dsl private constructor(
private val _builder: com.google.protobuf.Method.Builder
) {
public companion object {
@kotlin.jvm.JvmSynthetic
@kotlin.PublishedApi
internal fun _create(builder: com.google.protobuf.Method.Builder): Dsl = Dsl(builder)
}
@kotlin.jvm.JvmSynthetic
@kotlin.PublishedApi
internal fun _build(): com.google.protobuf.Method = _builder.build()
/**
* `string name = 1 [json_name = "name"];`
*/
public var name: kotlin.String
@JvmName("getName")
get() = _builder.getName()
@JvmName("setName")
set(value) {
_builder.setName(value)
}
/**
* `string name = 1 [json_name = "name"];`
*/
public fun clearName() {
_builder.clearName()
}
/**
* `string request_type_url = 2 [json_name = "requestTypeUrl"];`
*/
public var requestTypeUrl: kotlin.String
@JvmName("getRequestTypeUrl")
get() = _builder.getRequestTypeUrl()
@JvmName("setRequestTypeUrl")
set(value) {
_builder.setRequestTypeUrl(value)
}
/**
* `string request_type_url = 2 [json_name = "requestTypeUrl"];`
*/
public fun clearRequestTypeUrl() {
_builder.clearRequestTypeUrl()
}
/**
* `bool request_streaming = 3 [json_name = "requestStreaming"];`
*/
public var requestStreaming: kotlin.Boolean
@JvmName("getRequestStreaming")
get() = _builder.getRequestStreaming()
@JvmName("setRequestStreaming")
set(value) {
_builder.setRequestStreaming(value)
}
/**
* `bool request_streaming = 3 [json_name = "requestStreaming"];`
*/
public fun clearRequestStreaming() {
_builder.clearRequestStreaming()
}
/**
* `string response_type_url = 4 [json_name = "responseTypeUrl"];`
*/
public var responseTypeUrl: kotlin.String
@JvmName("getResponseTypeUrl")
get() = _builder.getResponseTypeUrl()
@JvmName("setResponseTypeUrl")
set(value) {
_builder.setResponseTypeUrl(value)
}
/**
* `string response_type_url = 4 [json_name = "responseTypeUrl"];`
*/
public fun clearResponseTypeUrl() {
_builder.clearResponseTypeUrl()
}
/**
* `bool response_streaming = 5 [json_name = "responseStreaming"];`
*/
public var responseStreaming: kotlin.Boolean
@JvmName("getResponseStreaming")
get() = _builder.getResponseStreaming()
@JvmName("setResponseStreaming")
set(value) {
_builder.setResponseStreaming(value)
}
/**
* `bool response_streaming = 5 [json_name = "responseStreaming"];`
*/
public fun clearResponseStreaming() {
_builder.clearResponseStreaming()
}
/**
* An uninstantiable, behaviorless type to represent the field in
* generics.
*/
@kotlin.OptIn(com.google.protobuf.kotlin.OnlyForUseByGeneratedProtoCode::class)
public class OptionsProxy private constructor() : com.google.protobuf.kotlin.DslProxy()
/**
* `repeated .google.protobuf.Option options = 6 [json_name = "options"];`
*/
public val options: com.google.protobuf.kotlin.DslList
@kotlin.jvm.JvmSynthetic
get() = com.google.protobuf.kotlin.DslList(
_builder.getOptionsList()
)
/**
* `repeated .google.protobuf.Option options = 6 [json_name = "options"];`
* @param value The options to add.
*/
@kotlin.jvm.JvmSynthetic
@kotlin.jvm.JvmName("addOptions")
public fun com.google.protobuf.kotlin.DslList.add(value: com.google.protobuf.Option) {
_builder.addOptions(value)
}
/**
* `repeated .google.protobuf.Option options = 6 [json_name = "options"];`
* @param value The options to add.
*/
@kotlin.jvm.JvmSynthetic
@kotlin.jvm.JvmName("plusAssignOptions")
@Suppress("NOTHING_TO_INLINE")
public inline operator fun com.google.protobuf.kotlin.DslList.plusAssign(value: com.google.protobuf.Option) {
add(value)
}
/**
* `repeated .google.protobuf.Option options = 6 [json_name = "options"];`
* @param values The options to add.
*/
@kotlin.jvm.JvmSynthetic
@kotlin.jvm.JvmName("addAllOptions")
public fun com.google.protobuf.kotlin.DslList.addAll(values: kotlin.collections.Iterable) {
_builder.addAllOptions(values)
}
/**
* `repeated .google.protobuf.Option options = 6 [json_name = "options"];`
* @param values The options to add.
*/
@kotlin.jvm.JvmSynthetic
@kotlin.jvm.JvmName("plusAssignAllOptions")
@Suppress("NOTHING_TO_INLINE")
public inline operator fun com.google.protobuf.kotlin.DslList.plusAssign(values: kotlin.collections.Iterable) {
addAll(values)
}
/**
* `repeated .google.protobuf.Option options = 6 [json_name = "options"];`
* @param index The index to set the value at.
* @param value The options to set.
*/
@kotlin.jvm.JvmSynthetic
@kotlin.jvm.JvmName("setOptions")
public operator fun com.google.protobuf.kotlin.DslList.set(index: kotlin.Int, value: com.google.protobuf.Option) {
_builder.setOptions(index, value)
}
/**
* `repeated .google.protobuf.Option options = 6 [json_name = "options"];`
*/
@kotlin.jvm.JvmSynthetic
@kotlin.jvm.JvmName("clearOptions")
public fun com.google.protobuf.kotlin.DslList.clear() {
_builder.clearOptions()
}
/**
* `.google.protobuf.Syntax syntax = 7 [json_name = "syntax"];`
*/
public var syntax: com.google.protobuf.Syntax
@JvmName("getSyntax")
get() = _builder.getSyntax()
@JvmName("setSyntax")
set(value) {
_builder.setSyntax(value)
}
public var syntaxValue: kotlin.Int
@JvmName("getSyntaxValue")
get() = _builder.getSyntaxValue()
@JvmName("setSyntaxValue")
set(value) {
_builder.setSyntaxValue(value)
}
/**
* `.google.protobuf.Syntax syntax = 7 [json_name = "syntax"];`
*/
public fun clearSyntax() {
_builder.clearSyntax()
}
}
}
@kotlin.jvm.JvmSynthetic
public inline fun com.google.protobuf.Method.copy(block: `com.google.protobuf`.MethodKt.Dsl.() -> kotlin.Unit): com.google.protobuf.Method =
`com.google.protobuf`.MethodKt.Dsl._create(this.toBuilder()).apply { block() }._build()